Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

can't query linked server 1

Status
Not open for further replies.

qotyebw

Programmer
Aug 24, 2000
103
US
I'm doing a new topic in a tutorial, linked servers.
I can already access the other server and DBs on my network from Enterprise Manager and as a new connection in Query analyzer. (SQL Server 2000)
All seems to be in place, except when I try to query the linked server(COMQUAT).

SELECT *
FROM COMQUAT.pubs.JoeBlow.authors

JoeBlow is a user on COMQUAT with owner rights to pubs

I get "Login failed for user 'COMQUAT\Guest'."
What's this about 'guest'?

I did :
sp_addlinkedsrvlogin
@rmtsrvname = 'COMQUAT',
@useself = 'false',
@locallogin = 'Administrator',
@rmtuser = 'JoeBlow',
@rmtpassword = 'xxxxxxx'

I do a sp_linkedservers, and it shows COMQUAT ok.
It is listed in EM's linked server list, but when I click on tables icon, I get the same error as above.

Maybe I don't need to know this stuff if I'm going to be using
mainly ASP.net, web services, etc?
 
I put a typo in that query, should read..

SELECT *
FROM COMQUAT.pubs.dbo.authors
 
That's the fix, Frederico.
I initially had a problem installing both instances of SQL Server with SQL authentication, so I used what worked at the time: windows auth only. After your suggestion, I managed to change them both to SQL-auth, and all is well now with linked-server access.

Thanks,
Chas R.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top