Get the old SQL servername

  • I recall a method to get the old servername of a SQL server but old age has gotten to me.

    I suspect a particular server has been renamed at one point. Obviously it wasn't me and the person before me is not around for me to ask.

    So, can someone help an old guy out?

    The results of print @@servername is NULL.

    Thanks

  • If this is a 2000 server, you could look at msdb..sysjobs. Chances are good that the local jobs have not been updated properly, and the originating_server is set to the original name. On 2005 this table refers to the server_id, so that will not help too much 🙁

    To fix the @@servername, run sp_addserver 'servername', 'local'

    Regards,

    Andras


    Andras Belokosztolszki, MCPD, PhD
    GoldenGate Software

Viewing 2 posts - 1 through 1 (of 1 total)

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