AndreasV
AndreasV

Reputation: 234

Can't access database in Azure Portal - "This resource was not found"

I have an SQL database in Azure that I use with my API. I can access the database from SQL Server Management Studio, and it seemto be alright - I can select data, make modifications and whatever. Although, I can't access it from Azure Portal.

"This resource was not found, it may have been deleted. /subscriptions/aee8966e-5891-40fb-8fff-8c359f43baee/resourceGroups/TestResourceGroup/providers/Microsoft.Sql/servers/testdbserver/databases/testdb"

Any ideas?

Update 2018-05-16: Jerry Liu suggested renaming the database, so I logged into SQL Server Management Studio, and this is what I found:

  1. I wasn't allowed to rename any of the databases on the server using right click --> Rename. The option is disabled.
  2. ALTER DATABASE carbonate_prod_180508 Modify Name = carbonate_renamed;
    Running this command, I get the error message "The source database 'carbonate_prod_180508' does not exist.". But I do see the database listed in the Object Explorer.

I also tried renaming it using Azure CLI. I find the database using "az sql db list" with the resource group name and server name, but when i run "az sql db rename" I get an error message stating the database was not found.

Upvotes: 0

Views: 1680

Answers (1)

Jerry Liu
Jerry Liu

Reputation: 17790

If you have done some operation like delete and recreate with same name or just move to another resource group, please wait a while for the operation to work completely.

Or if you have done nothing related, please try to rename your database in Management Studio and visit portal to check whether it's "back".

How to Rename SQL DB

Two methods for you to try

  • Click on database name twice slowly, or click once and push F2, just like we rename a file locally on Windows.
  • Create query on master database to execute alter operation.

Wait for about 30 seconds and refresh portal.

If none of them works, I recommend you to new a support request to Azure Team. It's the last blade in your Azure sql server panel.

Upvotes: 1

Related Questions