marsop
marsop

Reputation: 323

Merge Tables between Databases

I would like to move all the rows inside a couple of tables from one SQL Server database into another SQL Server located in a different remote server. This means I cannot connect to both at the same time, so the exchange should have to be done via file or a similar procedure. The tables have identical column definition, meaning it is only the data inside what differs. Also important to note, I do not expect a full overwrite, but rather a merge into the second database.

Upvotes: 0

Views: 102

Answers (3)

Rahul Sharma
Rahul Sharma

Reputation: 453

use SSIS it will be good it can be automated as well as you can change your configurations also . tomorrow if you got different server you just have to change connection strings and if it is a daily task use SSIS .

Upvotes: 0

steenbergh
steenbergh

Reputation: 1761

Could you create a linked server? http://msdn.microsoft.com/en-us/library/ff772782.aspx

Upvotes: 1

TheLittleHawk
TheLittleHawk

Reputation: 628

You can use SQL Management Studios export/import tool. It can extract data in CSV file, so you can save it on a disk, after that change connection to the new server and run import with exported file. This should do a trick.

Here is a nice and quick tutorial:

https://www.youtube.com/watch?v=Vf6pluv0Lv4

Upvotes: 1

Related Questions