Changing a Azure SQL Database Name

I had to rename an extant database in SQL Azure. Here’s what I did:

Using Powershell – Install the tools you need. Connect to the tennant. Then rename the DB! Simples!:

Install-Module -Name Az.Sql -AllowClobber
Connect-AzAccount -TenantId <Tenant ID>
Set-AzSqlDatabase -DatabaseName <sourceDbName> -NewName <targetDbName> -ServerName <server1> -ResourceGroupName <resgroup1>

Job Done

Changing a Azure SQL Database Name

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.