Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2005
    Posts
    58

    Unanswered: sp_linkedservers

    How do I run a query to check to see if "myserver" exist in sp_linkedservers?

  2. #2
    Join Date
    Aug 2005
    Posts
    5
    Quote Originally Posted by asahi
    How do I run a query to check to see if "myserver" exist in sp_linkedservers?
    Use Fully Qualified 4 Part Name and test the existance of the remote server.dbname.dbo.sysobjects, i.e.,
    IF Exists (select * from server.dbname.dbo.sysobjects....)

  3. #3
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    I'd use:
    Code:
    SELECT *
       FROM master.dbo.sysservers
       WHERE 'myserver' = srvname
    -PatP

  4. #4
    Join Date
    Oct 2005
    Posts
    58
    Thanks guys!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •