Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DateTime conversion

Status
Not open for further replies.

zishan619

Programmer
May 28, 2003
284
MX
Hi I need to know how to convert 01/01/2004 12:00:00 pm to
01/01/04 in T-sql.
Thanks
 
Check out CONVERT or CAST in BOL.

--Angel [rainbow]
-----------------------------------
Behold! As a wild ass in the desert
go forth I to do my work.
--Gurnie Hallock (Dune)
 
declare @TestDate DateTime
set @TestDate = '01/01/2004 12:00:00 pm'
print Convert(Char,@TestDate,1)

Thanks

J. Kusch
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top