How to change the instance name of SQL Server Express 2008 R2 edition.
hello friends when i installed sql server express 2008 R2 its inctanec name is coming HEMANT-PC\SQLEXPRESS this but i want only
HEMANT-PC friends plzz tell me how to do this witout reinstalling my sql is there any way
Posted Jul 11, 2012, 5:21 AM
Make sure you have backup of all the database if you are changing the production server instance name.
1 sp_helpserver
2 select @@servername
You can change the instance name using below query.
Default Instance
1 sp_dropserver 'old_name'
2 go
3 sp_addserver 'new_name','local'
4 go
Named Instance
1 sp_dropserver 'Server Name\old_Instance_name'
2 go
3 sp_addserver 'ServerName\New Instance Name','local'
4 go
Verify sql server instance configuration by running below queries
1 sp_helpserver
2 select @@servername
Restart the SQL Server Services.
1 net stop MSSQLServer
2 net start MSSQLServer
http://sqldbpool.com/2008/09/03/how-to-change-sql-server-instance-name/