October 17, 2012 at 10:27 am
There is different name in server properties and @@server name !!! can somebody explain how and why this happened and how to fix it??
server Properties name: abcdef
@@servername : abcxyz
October 17, 2012 at 11:41 am
Have you renamed the Windows server since sql server was installed?
To remove the current servername entry use
exec sp_dropserver 'abcxyz'
Then run this to correct it
exec sp_addserver 'abcdef', 'local'
-----------------------------------------------------------------------------------------------------------
"Ya can't make an omelette without breaking just a few eggs" 😉
October 17, 2012 at 2:13 pm
Is this on a cluster? When you say "server property" what are you selecting exactly?
@@servername will give the local machine name, except in a failover cluster, where it will give you the virtual server name
serverproperty('computernamephysicalnetbios') should give you the local machine name. In a failover cluster this is the machine name of the active node
Joie Andrew
"Since 1982"
October 18, 2012 at 7:01 am
when u right click on server's name in SSMS. i see different name and when i run select @@servername find different name.
October 18, 2012 at 7:15 am
Was the server renamed at some point? Can you post the results of the following:
SELECT SERVERPROPERTY(InstanceName), SERVERPROPERTY('MachineName'), SERVERPROPERTY('ComputerNamePhysicalNetbios'), SERVERPROPERTY('IsClustered')
Joie Andrew
"Since 1982"
October 18, 2012 at 8:19 am
dinsab11 (10/18/2012)
when u right click on server's name in SSMS. i see different name and when i run select @@servername find different name.
Please see my post above
-----------------------------------------------------------------------------------------------------------
"Ya can't make an omelette without breaking just a few eggs" 😉
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply