May 30, 2006 at 4:40 am
Lousy title, I know, but my problem is as follows;
I have an online 2K SQL server which is replicated as an instance on my local machine.
I have another 2K SQL server instance with a live certification db. The certification DB has a similar data structure to the online version, but has some differences between the tables.
I need to copy the latest data from my local machine, and transform it to match the live certification db.
I feel I can work out the T-SQL fine using "where NOT IN xxxxx... " okay, my problem is connecting between the instances of the db.
I have used the following --
EXEC sp_addlinkedserver CERTIFICATION
GO
EXEC sp_addlinkedsrvlogin @rmtsrvname = 'server1\CERTIFICATION', @useself = 'false', @locallogin = 'sa', @rmtuser = 'sa', @rmtpassword = 'XXXX'
GO
SELECT a.HospitalID
FROM server1\CERTIFICATION.mastercertification.dbo.thistable a
INNER JOIN server1.mastercertification.dbo.thistable b
ON a.thisColumn = b.this Column
GO
My error is "The object name 'server1.CERTIFICATION.mastercertification.dbo' contains more than the maximum number of prefixes. The maximum is 3."
I've tried slashes \ to no avail.
Any pointers would be greatly appreciated.
Thanks, Michael
May 30, 2006 at 5:17 am
Michael
Check out the topic Identifying a Data Source Using a Linked Server Name in Books Online.
John
May 30, 2006 at 5:34 am
Thanks, plowing through it as we speak . . .
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy