| Posted by rdraider on 08/23/07 22:57 
Thanks David.
 I know how to generate CREATE TABLE scripts but is there a fast way to
 generate INSERT statements for the actual data?
 
 
 
 "David Portas" <REMOVE_BEFORE_REPLYING_dportas@acm.org> wrote in message
 news:PZudnSBdYIxykVPbnZ2dnUVZ8qGdnZ2d@giganews.com...
 > "rdraider" <rdraider@sbcglobal.net> wrote in message
 > news:5_nzi.11029$3x.7225@newssvr25.news.prodigy.net...
 >> Correction the source field in an INT type
 >> So how to convert INT type YYYYMMDD to a date mm/dd/yyyy
 >>
 >>
 >
 >
 > DECLARE @dt INT;
 > SET @dt = 20070823;
 >
 > SELECT CAST(CAST(@dt AS CHAR(8)) AS DATETIME) AS dt;
 >
 > --
 > David Portas, SQL Server MVP
 >
 > Whenever possible please post enough code to reproduce your problem.
 > Including CREATE TABLE and INSERT statements usually helps.
 > State what version of SQL Server you are using and specify the content
 > of any error messages.
 >
 > SQL Server Books Online:
 > http://msdn2.microsoft.com/library/ms130214(en-US,SQL.90).aspx
 > --
 >
 >
  Navigation: [Reply to this message] |