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
 General SQL Server Forums
 New to SQL Server Programming
 How do I copy a table?

Author  Topic 

Conjurer
Starting Member

30 Posts

Posted - 2006-01-09 : 19:43:21
I want to update some values in a table using an update command. Lest I do something stupid and mess things up I would like to first make a copy of that table in case what I do creates some problems down the road.

We have a backup of the whole data base but I would like to make an additional copy of just this one table, just in case. It would also be nice to have just as a record of the before changes state.

How can I do that?

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2006-01-09 : 19:46:21
SELECT *
INTO BackupTable
FROM YourTable

Tara Kizer
aka tduggan
Go to Top of Page

Conjurer
Starting Member

30 Posts

Posted - 2006-01-09 : 19:58:37
Hey - Thanks!

Go to Top of Page
   

- Advertisement -