[dba-SQLServer] Convert DateTime to dd/mm/yyyy

Darren DICK darrend at nimble.com.au
Wed Mar 8 05:53:24 CST 2006


Hi all
In SQL, I am using convert to basically strip the time portion from a datetime
field
 
IE in the field we have the value...01/31/2005 11:05:34AM
What I want is 31/01/2005
 
I have had minor success using Convert
EG convert (char(10), BankingDate, 101)  AS 'BankingDate',  Gives me 01/31/2005 
Cool - I have been able to strip the time but it is still in &^%$#$% North
American date format 
ie mm/dd/yyyy
 
What I want is dd/mm/yyyy - IE 31/1/2005
 
Any suggestions?
 
Many thanks
 
DD
 



More information about the dba-SQLServer mailing list