Home All Groups Group Topic Archive Search About

appending a temporary table to another temporary table

Author
9 Dec 2005 5:31 PM
Mitch
I need to append one table to another.  The fields/columns headings are
identical in both tables.  How do I append one to the other using SQL (in
Query Analyzer)?

Author
9 Dec 2005 5:37 PM
Kalen Delaney
Hi Mitch

Try something like this:

INSERT INTO #temptable1
    SELECT * FROM #temptable2

--
HTH
Kalen Delaney, SQL Server MVP
www.solidqualitylearning.com


Show quote
"Mitch" <Mi***@discussions.microsoft.com> wrote in message
news:A0D31075-F452-4DF5-B78A-AA9482992986@microsoft.com...
>I need to append one table to another.  The fields/columns headings are
> identical in both tables.  How do I append one to the other using SQL (in
> Query Analyzer)?
>
Author
9 Dec 2005 5:38 PM
SQL
insert into tableA
select * from TableB



http://sqlservercode.blogspot.com/

AddThis Social Bookmark Button