Get Recoverable Database (classic)

 

Updated: October 5, 2016

THIS TOPIC APPLIES TO: noSQL Server yesAzure SQL DatabaseyesAzure SQL Data Warehouse noParallel Data Warehouse

Returns the details for a recoverable Azure SQL Database.

This command uses the classic deployment model. You should use the newer Resource Manager based REST API commands located here. For more information, see Azure Resource Manager vs. classic deployment: Understand deployment models and the state of your resources.

The Get Recoverable Database request must be specified as follows:

  • Replace {subscriptionId} with your subscription ID.

  • Replace {serverName} with the server name that contains the databases you want to list.

  • Replace {databaseName} with the name of the database you want to list.

MethodRequest URIHTTP Version
GEThttps://management.core.windows.net/{subscriptionId}/services/sqlservers/servers/{serverName}/recoverabledatabases/{databaseName}HTTP/1.1

URI Parameters

None.

Request Headers

The following table describes the required and optional request headers:

Request HeaderDescription
x-ms-client-request-idOptional. Provides a client-generated, opaque value with a 1 KB character limit. Using this header is highly recommended for correlating client-side activities with requests received by the server.

Request Body

None.

The response includes an HTTP status code, and a response body.

Status Code

Response status code 200 indicates the request succeeded.

Response Body

The following is an example response body:

<m:properties>  
        <d:Id m:type="Edm.Int32">{database-id}</d:Id>  
        <d:Name>{database-name}</d:Name>  
        <d:Edition>{database-edition}</d:Edition>  
        <d:LastAvailableBackupDate m:type="Edm.DateTime">{value}</d:LastAvailableBackupDate>  
</m:properties>  
  
<?xml version="1.0" encoding="utf-8" standalone="yes"?>  
<feed xml:base="https://abcd1234.database.windows.net/v1/ManagementService.svc/Server2('abcd1234')/" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">  
  <title type="text">DroppedDatabases</title>  
  <id>https://abcd1234.database.windows.net/v1/ManagementService.svc/Server2('serverName')/recoverabledatabases</id>  
  <updated>2012-11-09T17:59:43Z</updated>  
  <link rel="self" title="Databases" href="recoverabledatabases" />  
  <entry>  
    <id>https://jecvomngcv.database.windows.net/v1/ManagementService.svc/Server2/recoverabledatabases(1)</id>  
    <title type="text"></title>  
    <updated>2012-11-09T22:59:43Z</updated>  
    <author>  
      <name />  
    </author>  
    <link rel="edit" title="Database" href="recoverabledatabases(1)" />  
    <link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Server" type="application/atom+xml;type=entry" title="Server" href="recoverabledatabases(1)/Server" />  
    <link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/DatabaseMetrics" type="application/atom+xml;type=entry" title="DatabaseMetrics" href="recoverabledatabases(1)/DatabaseMetrics" />  
    <category term="Microsoft.SqlServer.Management.Server.Domain.RecoverableDatabase" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />  
    <content type="application/xml">  
      <m:properties>  
        <d:Id m:type="Edm.Int32">1</d:Id>  
        <d:Name>foo</d:Name>  
        <d:Edition>Basic</d:Edition>  
        <d:MaxSizeGB m:type="Edm.Int32">5</d:MaxSizeGB>  
        <d:CreationDate m:type="Edm.DateTime">{value}</d:CreationDate>  
        <d:LastAvailableBackupDate m:type="Edm.DateTime">{value}</d:LastAvailableBackupDate>  
      </m:properties>  
    </content>  
  </entry>  
</feed>  
  

The following table describes the elements in the response body:

Element NameDescription
IdThe identifier for this database.
NameThe name of the database.
EditionThe edition of the database.
MaxSizeGBThe maximum size of the database in GB.
CreationDateThe original creation date of the database.
LastAvailableBackupDateThe date of the last available backup for this database.

For a complete list of databases that can be recovered, see List Recoverable Databases (classic). To recover a recoverable database, see Create Database Recovery Request (classic).

Recover an Azure SQL database using Geo-Restore with REST API
Common REST API Error Codes
Azure SQL Database
Operations for Azure SQL Databases
Copying Databases in Azure SQL Database
Geo-Replication in Azure SQL Database
Azure SQL Database Cmdlets
Get-AzureSqlRecoverableDatabase

Show: