May 3, 2010 at 1:42 pm
How to get the date in mm/dd/yyyy when column datatype in smalldatetime
May 3, 2010 at 1:52 pm
grasshopper26 (5/3/2010)
How to get the date in mm/dd/yyyy when column datatype in smalldatetime
Date formatting should be done in the UI, not in SQL, but if you really need it, try this:
select
MyDateColumne,
convert(varchar(10), MyDateColumn, 102) as NewDate
from
dbo.MyTable;
May 3, 2010 at 2:00 pm
I tried the above but was not the mm/dd/yyy format and finally it by hit and trail
Convert(Varchar(12),MilestoneDate_BeginDate,110)
Thanks
May 3, 2010 at 2:03 pm
grasshopper26 (5/3/2010)
Convert(Varchar(12),MilestoneDate_BeginDate,110)
What did you get with 102? Never mind, you really want 101 for mm/dd/yyyy. Crooked eyes on my part.
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply