Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 how to update or insert data from one server to a

Author  Topic 

mohan123
Constraint Violating Yak Guru

252 Posts

Posted - 2012-12-11 : 06:58:35
hello all,

i have data of 100 records in one server with table name Population

and i have data 50 records of same table name in another server.if is sp_generate_inserts for that i need to delete data and again insert.But here i want to update as well as insert new records in mean time..suggest me

P.V.P.MOhan

nigelrivett
Master Smack Fu Yak Hacker

3385 Posts

Posted - 2012-12-11 : 07:07:28
Have a look at linked servers.

==========================================
Cursors are useful if you don't know sql.
SSIS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

mohan123
Constraint Violating Yak Guru

252 Posts

Posted - 2012-12-11 : 07:29:01
i am new to sql i never heard about linked servers

P.V.P.MOhan
Go to Top of Page

bandi
Master Smack Fu Yak Hacker

2242 Posts

Posted - 2012-12-11 : 07:42:05
Follow first link.. u can create linked server
1) http://www.quackit.com/sql_server/sql_server_2008/tutorial/linked_servers.cfm
(or)
http://msdn.microsoft.com/en-us/library/ff772782.aspx#SSMSProcedure

If u have any further information follow this one
http://www.quackit.com/sql_server/sql_server_2008/tutorial/linked_servers.cfm

Hence you can query that particular table and then do MERGE

--
Chandu
Go to Top of Page
   

- Advertisement -