sql server

By raovv06 ·
how to make copy of structure of table to another which is new one

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Answers

Collapse -

Here's 2 ways

by Tony Hopkinson In reply to sql server

Select Top 0 * Into MyNewTable
From MyOldTable

Will copy the Table structure, take out Top 0 if you want all the data.

Note no Primary key, index's or any other constraint will be copied.

If you want those, script the table to a file, rename as required and then execute.

Related Discussions

Related Forums