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 to store these values into other table?

Author  Topic 

samsun125
Yak Posting Veteran

63 Posts

Posted - 2009-01-22 : 01:23:05
Hi all,

I have one query , i want to store selected values into new table

how to store , that new table not yet created .



how to do

Regards
Rama

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2009-01-22 : 01:28:36
SELECT *
into destinationtable
FROM ...whatever you have written here...


E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

karthickbabu
Posting Yak Master

151 Posts

Posted - 2009-01-22 : 01:40:05

SELECT * INTO NewTableName FROM YourTableName

Its stores all columns.

If you need selected columns, try this

SELECT Column1,Column2,....ColumnN INTO NewTableName FROM YourTableName

====================================================
you realize you've made a mistake, take immediate steps to correct it.
Go to Top of Page
   

- Advertisement -