Database SQL Server

Renaming a SQL Server instance.


SQL> sp_dropserver 'oldservername';
SQL> sp_addserver 'newservername';

don’t run in same batch.
the two statements must be executed separately.

via sp_addserver Transact-SQL.