If the tables do not have IDENTITY columns, then this could work.
INSERT INTO database1.dbo.table
SELECT *
FROM database2.dbo.table
WHERE ID > 400
If the receiving table had an IDENTITY column, then add the following =
clarifications:
(Assuming Col1 is the IDENTITY column.)
INSERT INTO database1.dbo.table
( Col2
, Col3
, Col4
, etc
)
SELECT=20
Col2
, Col3
, Col5
, etc
FROM database2.dbo.table
WHERE ID > 400
--=20
Arnie Rowland
"To be successful, your heart must accompany your knowledge."
[quoted text, click to view] "Howard" <howdy0909@yahoo.com> wrote in message =
news:uaWV%23v8pGHA.3584@TK2MSFTNGP03.phx.gbl...
>I have two databases, both have a table with the exact same structure. =
i=20
> would like to merge the two databases, copy TABLE from database2 to =
TABLE=20
> database1 where ID column in database2 > 400
>=20
> thanks
> Howard=20
>=20