Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't delete azure database

Tags:

azure

In the sql server database list here:

https://manage.windowsazure.com/#Workspaces/SqlAzureExtension/Databases

I select a database and at the bottom is "Delete".

I press delete and it processes a little while then says:

Could not delete database 'system-50e5f905-...etc'

I follow a link for more details where it just says:

Bad Request

Extra info

They do not appear to be linked resources anywhere.

I have been able to create and delete a new database.

I have also connected using MS SQL server management studio and I can only see two named databases, none of the databases that have a name format of system-guid for a name.

like image 941
weston Avatar asked Jun 13 '13 10:06

weston


People also ask

How do I force delete a SQL database?

To remove a database from the current server without deleting the files from the file system, use sp_detach_db. USE master; ALTER DATABASE [databasename] SET SINGLE_USER WITH ROLLBACK IMMEDIATE; DROP DATABASE [databasename] ; Note, database backups will not be deleted as part of the process documented above.

How do I delete an entire database?

To delete a databaseExpand Databases, right-click the database to delete, and then click Delete. Confirm the correct database is selected, and then click OK.

How do I delete an Azure SQL server?

If you want to delete a server there are a couple of options. One simple way is to use the Remove-AzureSQLDatabaseServer PowerShell cmdlet. The following is an example: Remove-AzureSQLDatabaseServer -ServerName 'MY SERVER NAME' Just replace 'MY SERVER NAME' with the name of the server you want to delete.


1 Answers

Databases with the name format system-SOME GUID may be federations.

Deletion (Dropping) of a federation must be done within the database Management Portal for the main database.

Caution: I don't know the ramifications of dropping a federation, so make sure you have backups of data you don't want to loose or research this further.

  1. From https://manage.windowsazure.com/#Workspaces/SqlAzureExtension/Databases
  2. Select the main database
  3. Select "Design your SQL database"
  4. Log on
  5. At the top you see "server > [DB] > Tables", Click [DB]
  6. Federations are shown on this page and you can select them and "Drop Federation"
like image 184
weston Avatar answered Oct 15 '22 16:10

weston