Thursday, April 30, 2009

How to copy a table ?

Make a copy of an existing table

SELECT * INTO TargetTable FROM SourceTable


Make a copy of the structure of an existing table

SELECT * INTO
TargetTable FROM SourceTable WHERE 1=0

No comments:

Post a Comment