If 200401 is Jan 2004 then:
convert(datetime,'200401'+'01',112)
gives you Jan 01, 2004 as a datetime
-----Original Message-----
From: Elena Frenkel
[mailto:mssqldba-ezmlmshield-x68560005.[Email address protected]
Sent: Tuesday, February 22, 2005 12:47 PM
To: LazyDBA Discussion
Subject: Any idea
I have a column (char) with info like 200401, how to insert this into a
table in a column with a date type in SQL server 2000.
I appreciate any idea..
---------------------------------------------------------------------
TO REPLY TO EVERBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY Website :
http://www.LazyDBA.com To unsubscribe:
http://www.lazydba.com/unsubscribe.html
For additional commands, e-mail: mssqldba-[Email address protected]
--
This message has been scanned for viruses and dangerous content by
MailScanner, and is believed to be clean.
Douglas County, Oregon
www.co.douglas.or.us
MS Sql Server LazyDBA home page