Saturday, February 25, 2012

Change the @@Servername

Hi,
We have changed the server name. If I run select @.@.servername, it came out
the same server name.
any ideas>
Thanks,Change the script below to specify the new server name and execute. Then
restart SQL Server.
EXEC sp_dropserver @.@.SERVERNAME
EXEC sp_addserver 'NewServerName', 'local'
--
Hope this helps.
Dan Guzman
SQL Server MVP
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
> Hi,
> We have changed the server name. If I run select @.@.servername, it came out
> the same server name.
> any ideas>
> Thanks,
>|||Check out sp_dropserver and sp_addserver in the BOL.
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Toronto, ON Canada
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
Hi,
We have changed the server name. If I run select @.@.servername, it came out
the same server name.
any ideas>
Thanks,|||thanks all
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
> Hi,
> We have changed the server name. If I run select @.@.servername, it came out
> the same server name.
> any ideas>
> Thanks,
>|||In addition, if you had any SQL Agent jobs defined before the rename you
need to take an additional step or you won't be able to modify them. See
http://www.karaszi.com/SQLServer/info_change_server_name.asp
--
HTH,
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
> Hi,
> We have changed the server name. If I run select @.@.servername, it came out
> the same server name.
> any ideas>
> Thanks,
>|||thanks all
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
> Hi,
> We have changed the server name. If I run select @.@.servername, it came out
> the same server name.
> any ideas>
> Thanks,
>|||thanks all
"mecn" <mecn2002@.yahoo.com> wrote in message
news:OsK7a4brGHA.4508@.TK2MSFTNGP04.phx.gbl...
> Hi,
> We have changed the server name. If I run select @.@.servername, it came out
> the same server name.
> any ideas>
> Thanks,
>

No comments:

Post a Comment