Reputation: 749
Is it posible to change instance name in SQL SERVER? Now I have ./MSSQLR2
and
I would like ./SQLEXPRESS
. I was trying to do this through this commands
--sp_dropserver 'HYDROGEN\MSSQLR2';
--sp_addserver 'HYDROGEN\MSSQLR2', local;
and then restart server, but It seems not work.
Upvotes: 7
Views: 60892
Reputation: 21766
For future reference, sp_dropserver
and sp_addserver
can only be used to rename the part of the instance name that corresponds to the computer name. So you could use it to rename your server name HYDROGEN
to HELIUM
, but you can't change the instance name MSQSQLR2
without reinstalling (see Jerome Bradley's answer). For details can be found on MSDN.
sp_dropserver 'HYDROGEN\MSSQLR2';
GO
sp_addserver 'HELIUM\MSSQLR2', local;
GO
Upvotes: 5
Reputation: 64943
You can create instance aliases: http://www.mssqltips.com/tip.asp?tip=1620
Upvotes: -2