Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 datetime format

Author  Topic 

cognos79
Posting Yak Master

241 Posts

Posted - 2007-01-12 : 01:09:34
I need to convert date into this format:
mon dd yyyy hh:mi:ssAM (or PM).

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2007-01-12 : 03:49:59
[code]select stuff(convert(varchar(30), getdate(),109),21,4,'')[/code]

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

cognos79
Posting Yak Master

241 Posts

Posted - 2007-01-15 : 18:14:52
thanks harsh...it worked
Go to Top of Page
   

- Advertisement -