Tutorials

SQL Table


SQL Copy Table


Copying a table into another table is possible in SQL. You can do it using SELECT statement.

 

Syntax for copying a table to other table

SELECT * INTO destinationTableName FROM sourceTableName;

Example on copying a table to other table

Suppose we want to copy a table say Table1 into Table2.

So we need to write following sql query.

SELECT * INTO Table2 FROM Table1;

The above query will copy entire table Table1 into Table2.

 

There are lot more things that we can do with SELECT statement in sql. We will learn all in SELECT section of this tutorial.

 

 



Please Share this page
Views : 93
Like every other website we use cookies. By using our site you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service. Learn more Got it!