class Azure::SQL::Mgmt::V2014_04_01::Models::DatabaseUpdate

Represents a database update.

Attributes

collation[RW]

@return [String] The collation of the database. If createMode is not Default, this value is ignored.

containment_state[RW]

@return [Integer] The containment state of the database.

create_mode[RW]

@return [CreateMode] Specifies the mode of database creation.

Default: regular database creation.

Copy: creates a database as a copy of an existing database. sourceDatabaseId must be specified as the resource ID of the source database.

OnlineSecondary/NonReadableSecondary: creates a database as a (readable or nonreadable) secondary replica of an existing database. sourceDatabaseId must be specified as the resource ID of the existing primary database.

PointInTimeRestore: Creates a database by restoring a point in time backup of an existing database. sourceDatabaseId must be specified as the resource ID of the existing database, and restorePointInTime must be specified.

Recovery: Creates a database by restoring a geo-replicated backup. sourceDatabaseId must be specified as the recoverable database resource ID to restore.

Restore: Creates a database by restoring a backup of a deleted database. sourceDatabaseId must be specified. If sourceDatabaseId is the database's original resource ID, then sourceDatabaseDeletionDate must be specified. Otherwise sourceDatabaseId must be the restorable dropped database resource ID and sourceDatabaseDeletionDate is ignored. restorePointInTime may also be specified to restore from an earlier point in time.

RestoreLongTermRetentionBackup: Creates a database by restoring from a long term retention vault. recoveryServicesRecoveryPointResourceId must be specified as the recovery point resource ID.

Copy, NonReadableSecondary, OnlineSecondary and RestoreLongTermRetentionBackup are not supported for DataWarehouse edition. Possible values include: 'Copy', 'Default', 'NonReadableSecondary', 'OnlineSecondary', 'PointInTimeRestore', 'Recovery', 'Restore', 'RestoreLongTermRetentionBackup'

creation_date[RW]

@return [DateTime] The creation date of the database (ISO8601 format).

current_service_objective_id[RW]

@return The current service level objective ID of the database. This is the ID of the service level objective that is currently active.

database_id[RW]

@return The ID of the database.

default_secondary_location[RW]

@return [String] The default secondary region for this database.

earliest_restore_date[RW]

@return [DateTime] This records the earliest start date and time that restore is available for this database (ISO8601 format).

edition[RW]

@return [DatabaseEdition] The edition of the database. The DatabaseEditions enumeration contains all the valid editions. If createMode is NonReadableSecondary or OnlineSecondary, this value is ignored.

The list of SKUs may vary by region and support offer. To determine the SKUs (including the SKU name, tier/edition, family, and capacity) that are available to your subscription in an Azure region, use the `Capabilities_ListByLocation` REST API or one of the following commands:

“`azurecli az sql db list-editions -l <location> -o table ““

“`powershell Get-AzSqlServerServiceObjective -Location <location> ““ . Possible values include: 'Web', 'Business', 'Basic', 'Standard', 'Premium', 'PremiumRS', 'Free', 'Stretch', 'DataWarehouse', 'System', 'System2', 'GeneralPurpose', 'BusinessCritical', 'Hyperscale'

elastic_pool_name[RW]

@return [String] The name of the elastic pool the database is in. If elasticPoolName and requestedServiceObjectiveName are both updated, the value of requestedServiceObjectiveName is ignored. Not supported for DataWarehouse edition.

failover_group_id[RW]

@return [String] The resource identifier of the failover group containing this database.

max_size_bytes[RW]

@return [String] The max size of the database expressed in bytes. If createMode is not Default, this value is ignored. To see possible values, query the capabilities API (/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationID}/capabilities) referred to by operationId: “Capabilities_ListByLocation.”

read_scale[RW]

@return [ReadScale] Conditional. If the database is a geo-secondary, readScale indicates whether read-only connections are allowed to this database or not. Not supported for DataWarehouse edition. Possible values include: 'Enabled', 'Disabled'

recovery_services_recovery_point_resource_id[RW]

@return [String] Conditional. If createMode is RestoreLongTermRetentionBackup, then this value is required. Specifies the resource ID of the recovery point to restore from.

requested_service_objective_id[RW]

@return The configured service level objective ID of the database. This is the service level objective that is in the process of being applied to the database. Once successfully updated, it will match the value of currentServiceObjectiveId property. If requestedServiceObjectiveId and requestedServiceObjectiveName are both updated, the value of requestedServiceObjectiveId overrides the value of requestedServiceObjectiveName.

The list of SKUs may vary by region and support offer. To determine the service objective ids that are available to your subscription in an Azure region, use the `Capabilities_ListByLocation` REST API.

requested_service_objective_name[RW]

@return [ServiceObjectiveName] The name of the configured service level objective of the database. This is the service level objective that is in the process of being applied to the database. Once successfully updated, it will match the value of serviceLevelObjective property.

The list of SKUs may vary by region and support offer. To determine the SKUs (including the SKU name, tier/edition, family, and capacity) that are available to your subscription in an Azure region, use the `Capabilities_ListByLocation` REST API or one of the following commands:

“`azurecli az sql db list-editions -l <location> -o table ““

“`powershell Get-AzSqlServerServiceObjective -Location <location> ““ . Possible values include: 'System', 'System0', 'System1', 'System2', 'System3', 'System4', 'System2L', 'System3L', 'System4L', 'Free', 'Basic', 'S0', 'S1', 'S2', 'S3', 'S4', 'S6', 'S7', 'S9', 'S12', 'P1', 'P2', 'P3', 'P4', 'P6', 'P11', 'P15', 'PRS1', 'PRS2', 'PRS4', 'PRS6', 'DW100', 'DW200', 'DW300', 'DW400', 'DW500', 'DW600', 'DW1000', 'DW1200', 'DW1000c', 'DW1500', 'DW1500c', 'DW2000', 'DW2000c', 'DW3000', 'DW2500c', 'DW3000c', 'DW6000', 'DW5000c', 'DW6000c', 'DW7500c', 'DW10000c', 'DW15000c', 'DW30000c', 'DS100', 'DS200', 'DS300', 'DS400', 'DS500', 'DS600', 'DS1000', 'DS1200', 'DS1500', 'DS2000', 'ElasticPool'

restore_point_in_time[RW]

@return [DateTime] Conditional. If createMode is PointInTimeRestore, this value is required. If createMode is Restore, this value is optional. Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database. Must be greater than or equal to the source database's earliestRestoreDate value.

sample_name[RW]

@return [SampleName] Indicates the name of the sample schema to apply when creating this database. If createMode is not Default, this value is ignored. Not supported for DataWarehouse edition. Possible values include: 'AdventureWorksLT'

service_level_objective[RW]

@return [ServiceObjectiveName] The current service level objective of the database. Possible values include: 'System', 'System0', 'System1', 'System2', 'System3', 'System4', 'System2L', 'System3L', 'System4L', 'Free', 'Basic', 'S0', 'S1', 'S2', 'S3', 'S4', 'S6', 'S7', 'S9', 'S12', 'P1', 'P2', 'P3', 'P4', 'P6', 'P11', 'P15', 'PRS1', 'PRS2', 'PRS4', 'PRS6', 'DW100', 'DW200', 'DW300', 'DW400', 'DW500', 'DW600', 'DW1000', 'DW1200', 'DW1000c', 'DW1500', 'DW1500c', 'DW2000', 'DW2000c', 'DW3000', 'DW2500c', 'DW3000c', 'DW6000', 'DW5000c', 'DW6000c', 'DW7500c', 'DW10000c', 'DW15000c', 'DW30000c', 'DS100', 'DS200', 'DS300', 'DS400', 'DS500', 'DS600', 'DS1000', 'DS1200', 'DS1500', 'DS2000', 'ElasticPool'

service_tier_advisors[RW]

@return [Array<ServiceTierAdvisor>] The list of service tier advisors for this database. Expanded property

source_database_deletion_date[RW]

@return [DateTime] Conditional. If createMode is Restore and sourceDatabaseId is the deleted database's original resource id when it existed (as opposed to its current restorable dropped database id), then this value is required. Specifies the time that the database was deleted.

source_database_id[RW]

@return [String] Conditional. If createMode is Copy, NonReadableSecondary, OnlineSecondary, PointInTimeRestore, Recovery, or Restore, then this value is required. Specifies the resource ID of the source database. If createMode is NonReadableSecondary or OnlineSecondary, the name of the source database must be the same as the new database being created.

status[RW]

@return [String] The status of the database.

tags[RW]

@return [Hash{String => String}] Resource tags.

transparent_data_encryption[RW]

@return [Array<TransparentDataEncryption>] The transparent data encryption info for this database.

zone_redundant[RW]

@return [Boolean] Whether or not this database is zone redundant, which means the replicas of this database will be spread across multiple availability zones.

Public Class Methods

mapper() click to toggle source

Mapper for DatabaseUpdate class as Ruby Hash. This will be used for serialization/deserialization.

# File lib/2014-04-01/generated/azure_mgmt_sql/models/database_update.rb, line 244
def self.mapper()
  {
    client_side_validation: true,
    required: false,
    serialized_name: 'DatabaseUpdate',
    type: {
      name: 'Composite',
      class_name: 'DatabaseUpdate',
      model_properties: {
        id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'id',
          type: {
            name: 'String'
          }
        },
        name: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'name',
          type: {
            name: 'String'
          }
        },
        type: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'type',
          type: {
            name: 'String'
          }
        },
        tags: {
          client_side_validation: true,
          required: false,
          serialized_name: 'tags',
          type: {
            name: 'Dictionary',
            value: {
                client_side_validation: true,
                required: false,
                serialized_name: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        collation: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.collation',
          type: {
            name: 'String'
          }
        },
        creation_date: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.creationDate',
          type: {
            name: 'DateTime'
          }
        },
        containment_state: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.containmentState',
          type: {
            name: 'Number'
          }
        },
        current_service_objective_id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.currentServiceObjectiveId',
          type: {
            name: 'String'
          }
        },
        database_id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.databaseId',
          type: {
            name: 'String'
          }
        },
        earliest_restore_date: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.earliestRestoreDate',
          type: {
            name: 'DateTime'
          }
        },
        create_mode: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.createMode',
          type: {
            name: 'String'
          }
        },
        source_database_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.sourceDatabaseId',
          type: {
            name: 'String'
          }
        },
        source_database_deletion_date: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.sourceDatabaseDeletionDate',
          type: {
            name: 'DateTime'
          }
        },
        restore_point_in_time: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.restorePointInTime',
          type: {
            name: 'DateTime'
          }
        },
        recovery_services_recovery_point_resource_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.recoveryServicesRecoveryPointResourceId',
          type: {
            name: 'String'
          }
        },
        edition: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.edition',
          type: {
            name: 'String'
          }
        },
        max_size_bytes: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.maxSizeBytes',
          type: {
            name: 'String'
          }
        },
        requested_service_objective_id: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.requestedServiceObjectiveId',
          type: {
            name: 'String'
          }
        },
        requested_service_objective_name: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.requestedServiceObjectiveName',
          type: {
            name: 'String'
          }
        },
        service_level_objective: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.serviceLevelObjective',
          type: {
            name: 'String'
          }
        },
        status: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.status',
          type: {
            name: 'String'
          }
        },
        elastic_pool_name: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.elasticPoolName',
          type: {
            name: 'String'
          }
        },
        default_secondary_location: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.defaultSecondaryLocation',
          type: {
            name: 'String'
          }
        },
        service_tier_advisors: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.serviceTierAdvisors',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'ServiceTierAdvisorElementType',
                type: {
                  name: 'Composite',
                  class_name: 'ServiceTierAdvisor'
                }
            }
          }
        },
        transparent_data_encryption: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.transparentDataEncryption',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'TransparentDataEncryptionElementType',
                type: {
                  name: 'Composite',
                  class_name: 'TransparentDataEncryption'
                }
            }
          }
        },
        recommended_index: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.recommendedIndex',
          type: {
            name: 'Sequence',
            element: {
                client_side_validation: true,
                required: false,
                serialized_name: 'RecommendedIndexElementType',
                type: {
                  name: 'Composite',
                  class_name: 'RecommendedIndex'
                }
            }
          }
        },
        failover_group_id: {
          client_side_validation: true,
          required: false,
          read_only: true,
          serialized_name: 'properties.failoverGroupId',
          type: {
            name: 'String'
          }
        },
        read_scale: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.readScale',
          type: {
            name: 'Enum',
            module: 'ReadScale'
          }
        },
        sample_name: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.sampleName',
          type: {
            name: 'String'
          }
        },
        zone_redundant: {
          client_side_validation: true,
          required: false,
          serialized_name: 'properties.zoneRedundant',
          type: {
            name: 'Boolean'
          }
        }
      }
    }
  }
end