query from a server a DB a1 to a serverB db b2

  • Hi

    I'd like to create  a management SLQ SERVER which will make report for all db on all servers.

    My problem is to do queries from Mgt server to other server.

    I have some ideas but I'd like to have your opinions .

    Thanks for you help !

     

  • Look up sp_addlinkedserver in BOL and see if that helps.

     

     

    ------------

    Ray Higdon MCSE, MCDBA, CCNA

  • yes it does ! Thank you, I will create my proc with DB link

     

  • A other question :

    I make dbcc checkdb every nights on each DB.

    The result is store in a file I send me by mail.

     

    QUESTION :

    how can I centralized the process by create the log file on my mgt server ?

    exec dbcc checkdb(linkedserver.db) doesn't work.

  • There are different ways to do this, for something like this linked servers may be a pain and I would use a DTS package to run the SQL scripts on each server. You could then concat the files into one and email you it. You may find more resources on this type of task at http://www.sqldts.com

     

    HTH

    ------------

    Ray Higdon MCSE, MCDBA, CCNA

  • Whenever I use linked servers, I use a view to hide the extra complexity and confusion.   It also saves typing the extra dots

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply