SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 linked severs
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

kt
Yak Posting Veteran

82 Posts

Posted - 02/14/2013 :  15:15:03  Show Profile  Reply with Quote
Hi,

I have 2 servers A and B.
In A, I have database name App.
In B, I have two databases name COST, ODRS.

From A, I do the query to use the link to call the DB :COST in B
such as: select * from mylinkB.COST.dbo.mytbl - WORKED

However got error when call db ODRS
such as: select * from mylinkB.ODRS.dbo.mytbl

error:Msg 7314, Level 16, State 1, Line 1
The OLE DB provider "SQLNCLI" for linked server "mylinkB" does not contain the table ""ODRS"."dbo"."mytbl"". The table either does not exist or the current user does not have permissions on that table.

what's wrong with this, pls advice

thanks

kt

srimami
Posting Yak Master

160 Posts

Posted - 02/14/2013 :  18:02:13  Show Profile  Reply with Quote
While creating linked server, the product catalogue has added Database COST but not ORDS. Either create another linked server with ORDS database or add this database to the existing connection.
Go to Top of Page

Bustaz Kool
Flowing Fount of Yak Knowledge

USA
1721 Posts

Posted - 02/14/2013 :  18:45:49  Show Profile  Reply with Quote
How are you defining security for the linked server? It sounds like the security context used by the linked server does not have rights to the ORDS database.

=================================================
There are two kinds of light -- the glow that illuminates, and the glare that obscures. -James Thurber
Go to Top of Page

kt
Yak Posting Veteran

82 Posts

Posted - 02/19/2013 :  15:09:45  Show Profile  Reply with Quote
i didn't created the links, where i can look at to see if the DB is tied to this sever?
Go to Top of Page

Bustaz Kool
Flowing Fount of Yak Knowledge

USA
1721 Posts

Posted - 02/19/2013 :  16:26:53  Show Profile  Reply with Quote
From the Object Explorer pane in SSMS: Server Objects->Linked Servers. Right click the linked server in question, select Properties and click on Security. Do you have Login Mappings defined (top)? Which of the four radio buttons (bottom) is selected? If the last one, note which Login/Password is defined. You don't need to tell us what the Login/Password combination is, clearly, but see if you can use those credentials at the target server and gain access to the desired database. Let us know and we'll work through the details.

=================================================
There are two kinds of light -- the glow that illuminates, and the glare that obscures. -James Thurber

Edited by - Bustaz Kool on 02/19/2013 16:36:53
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000