November 8, 2010 at 11:47 pm
I want to back up some rows of table from sql
then restore rows to another database. I have two table with relation
November 9, 2010 at 2:35 am
This sounds like a job best suited for SSIS rather than a backup / restore
November 10, 2010 at 12:34 pm
sfr_rezaei (11/8/2010)
I want to back up some rows of table from sqlthen restore rows to another database. I have two table with relation
How about using Linked server (if it is required as a permanaent) or opendata source if it is one time
if the table already exists then:
insert into databasename.dbo.tablename
select * from linkedserver.dbname.dbo.tablename
insert into databasename.dbo.tablename
select * from opendatasource ('SQLOLEDB','Data Source=<ip,portno>; User ID=<username>;Password=<password>').dbname.dbo.tablename
Ofcourse SSIS is also another way of doing it.
HTH,
Cheers
______________________________________________________________________________________________________________________________________________________________________________________
HTH !
Kin
MCTS : 2005, 2008
Active SQL Server Community Contributor 🙂
November 10, 2010 at 12:34 pm
sfr_rezaei (11/8/2010)
I want to back up some rows of table from sqlthen restore rows to another database. I have two table with relation
How about using Linked server (if it is required as a permanaent) or opendata source if it is one time
if the table already exists then:
insert into databasename.dbo.tablename
select * from linkedserver.dbname.dbo.tablename
insert into databasename.dbo.tablename
select * from opendatasource ('SQLOLEDB','Data Source=<ip,portno>; User ID=<username>;Password=<password>').dbname.dbo.tablename
Ofcourse SSIS is also another way of doing it.
HTH,
Cheers
______________________________________________________________________________________________________________________________________________________________________________________
HTH !
Kin
MCTS : 2005, 2008
Active SQL Server Community Contributor 🙂
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply