NealR
NealR

Reputation: 10709

T-SQL Script to copy data from one server to another?

Is it possible to copy data from one server to another using a T-SQL script? We have a code promotion process that makes using the import wizard less than optimal for our team so I am looking into a script I can simply have someone run in Management Studio that will do the trick.

Upvotes: 0

Views: 150

Answers (1)

Reza
Reza

Reputation: 19933

Yes, First create a Linked Server to other server, then you can access the target server by 4 part Names, for example:

Insert into Server2.Database2.dbo.MapTable1 select * from table1

p.s you can add linked server by sp_addLinkedServer

Upvotes: 3

Related Questions