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.
Author |
Topic |
mnarewec
Starting Member
10 Posts |
Posted - 2009-07-07 : 17:58:58
|
TeamI am trying to get data from database in one server and insert into same database in another server.I linked an instance of SQL Server 2005 (WAI_ISNT_TTS\DEVELOPMENT) to my local SQL Server 2005 Express Ed server (WAIITD91\SQLEXPRESS. It is a default instance)Here is the script for Link Server:EXEC sp_addlinkedserver @server='WAI_ISNT_TTS', @srvproduct='', @provider='SQLNCLI', @datasrc='WAI_ISNT_TTS\DEVELOPMENT'Here is my script of SQL Insert Statement:insert into WAIITD91.SQLEXPRESS.FMS.Regionsselect * FROM WAI_ISNT_TTS.DEVELOPMENT.FMS.RegionsHowever I got this Error when executing the Insert statement Script:The OLE DB provider "SQLNCLI" for linked server "WAI_ISNT_TTS" does not contain the table ""DEVELOPMENT"."FMS"."Regions"". The table either does not exist or the current user does not have permissions on that table.Please advise where I went wrong. On the SQL Insert statement script or the Link Server script??Thanks in advance for your helpCheers!Marsh |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2009-07-08 : 04:50:40
|
you need to add a login to the linked server.Look up sp_addlinkedsrvlogin in BOL. |
 |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-07-11 : 19:30:21
|
quote: Originally posted by mnarewec TeamI am trying to get data from database in one server and insert into same database in another server.I linked an instance of SQL Server 2005 (WAI_ISNT_TTS\DEVELOPMENT) to my local SQL Server 2005 Express Ed server (WAIITD91\SQLEXPRESS. It is a default instance)Here is the script for Link Server:EXEC sp_addlinkedserver @server='WAI_ISNT_TTS', @srvproduct='', @provider='SQLNCLI', @datasrc='WAI_ISNT_TTS\DEVELOPMENT'Here is my script of SQL Insert Statement:[green]insert into [WAIITD91\SQLEXPRESS].DatabaseName.FMS(Schema).Regionsselect * FROM FMS.Regions [/green]However I got this Error when executing the Insert statement Script:The OLE DB provider "SQLNCLI" for linked server "WAI_ISNT_TTS" does not contain the table ""DEVELOPMENT"."FMS"."Regions"". The table either does not exist or the current user does not have permissions on that table.Please advise where I went wrong. On the SQL Insert statement script or the Link Server script??Thanks in advance for your helpCheers!Marsh
|
 |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2009-07-13 : 04:20:31
|
And we wonder why sodeep's post count is so high.. |
 |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-07-13 : 22:26:57
|
Well I have slowed down nowdays. |
 |
|
|
|
|