Rename database name in MSSQL May 01, 2019 To rename the database is MSSQL, use below queries. ALTER DATABASE srcDatabaseName SET SINGLE_USER WITH ROLLBACK IMMEDIATE; GO sp_rename ' srcDatabaseName' , ' dest DatabaseName ' ,'DATABASE'; GO ALTER DATABASE dest DatabaseName SET MULTI_USER; Read more