October 16, 2009 at 8:27 am
Hi folks,
I've looked everywhere to find a technique that will format the date as dd-mmm-yyyy within a stored proc without using a function.
Does anyone know if there are any articles or ways to do this? The format's not built into SQL server.
Thanks
October 16, 2009 at 8:35 am
Thanks for anyone who looks at this, however, I found the answer
select replace(convert(char(11),getdate(),113),' ','-')
Cheers
October 16, 2009 at 9:15 am
Most of the formats are here: http://msdn.microsoft.com/en-us/library/ms187928.aspx
October 16, 2009 at 9:18 am
Cheers Steve, I looked at BOL, however I didn't notice 113.
🙂
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply