Is it posible to change instance name in SQL SERVER? Now I have ./MSSQLR2 andI 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.

2

Best Answer


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';GOsp_addserver 'HELIUM\MSSQLR2', local;GO

You can create instance aliases:http://www.mssqltips.com/tip.asp?tip=1620