azure.mgmt.sql.operations module

class azure.mgmt.sql.operations.RecoverableDatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

RecoverableDatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.RecoverableDatabase’[source]

Gets a recoverable database, which is a resource representing a database’s geo backup.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RecoverableDatabase, or the result of cls(response)

Return type

RecoverableDatabase

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.RecoverableDatabaseListResult’][source]

Gets a list of recoverable databases.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RecoverableDatabaseListResult or the result of cls(response)

Return type

ItemPaged[RecoverableDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.RestorableDroppedDatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

RestorableDroppedDatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, restorable_droppeded_database_id: str, **kwargs: Any) → ’models.RestorableDroppedDatabase’[source]

Gets a deleted database that can be restored.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • restorable_droppeded_database_id (str) – The id of the deleted database in the form of databaseName,deletionTimeInFileTimeFormat.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RestorableDroppedDatabase, or the result of cls(response)

Return type

RestorableDroppedDatabase

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.RestorableDroppedDatabaseListResult’][source]

Gets a list of deleted databases that can be restored.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RestorableDroppedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[RestorableDroppedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerConnectionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerConnectionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, connection_policy_name: Union[str, ‘models.ConnectionPolicyName’], parameters: ‘models.ServerConnectionPolicy’, **kwargs: Any) → ’models.ServerConnectionPolicy’[source]

Creates or updates the server’s connection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • connection_policy_name (str or ConnectionPolicyName) – The name of the connection policy.

  • parameters (ServerConnectionPolicy) – The required parameters for updating a secure connection policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerConnectionPolicy, or the result of cls(response)

Return type

ServerConnectionPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, connection_policy_name: Union[str, ‘models.ConnectionPolicyName’], **kwargs: Any) → ’models.ServerConnectionPolicy’[source]

Gets the server’s secure connection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • connection_policy_name (str or ConnectionPolicyName) – The name of the connection policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerConnectionPolicy, or the result of cls(response)

Return type

ServerConnectionPolicy

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseThreatDetectionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseThreatDetectionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyName’], parameters: ‘models.DatabaseSecurityAlertPolicy’, **kwargs: Any) → ’models.DatabaseSecurityAlertPolicy’[source]

Creates or updates a database’s threat detection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which database Threat Detection policy is defined.

  • security_alert_policy_name (str or SecurityAlertPolicyName) – The name of the security alert policy.

  • parameters (DatabaseSecurityAlertPolicy) – The database Threat Detection policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseSecurityAlertPolicy, or the result of cls(response)

Return type

DatabaseSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyName’], **kwargs: Any) → ’models.DatabaseSecurityAlertPolicy’[source]

Gets a database’s threat detection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which database Threat Detection policy is defined.

  • security_alert_policy_name (str or SecurityAlertPolicyName) – The name of the security alert policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseSecurityAlertPolicy, or the result of cls(response)

Return type

DatabaseSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DataMaskingPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

DataMaskingPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.DataMaskingPolicy’, **kwargs: Any) → ’models.DataMaskingPolicy’[source]

Creates or updates a database data masking policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (DataMaskingPolicy) – Parameters for creating or updating a data masking policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DataMaskingPolicy, or the result of cls(response)

Return type

DataMaskingPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.DataMaskingPolicy’[source]

Gets a database data masking policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DataMaskingPolicy, or the result of cls(response)

Return type

DataMaskingPolicy

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DataMaskingRulesOperations(client, config, serializer, deserializer)[source]

Bases: object

DataMaskingRulesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, data_masking_rule_name: str, parameters: ‘models.DataMaskingRule’, **kwargs: Any) → ’models.DataMaskingRule’[source]

Creates or updates a database data masking rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • data_masking_rule_name (str) – The name of the data masking rule.

  • parameters (DataMaskingRule) – The required parameters for creating or updating a data masking rule.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DataMaskingRule, or the result of cls(response)

Return type

DataMaskingRule

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DataMaskingRuleListResult’][source]

Gets a list of database data masking rules.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DataMaskingRuleListResult or the result of cls(response)

Return type

ItemPaged[DataMaskingRuleListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.FirewallRulesOperations(client, config, serializer, deserializer)[source]

Bases: object

FirewallRulesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, firewall_rule_name: str, parameters: ‘models.FirewallRule’, **kwargs: Any) → ’models.FirewallRule’[source]

Creates or updates a firewall rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • firewall_rule_name (str) – The name of the firewall rule.

  • parameters (FirewallRule) – The required parameters for creating or updating a firewall rule.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

FirewallRule, or the result of cls(response)

Return type

FirewallRule

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, firewall_rule_name: str, **kwargs: Any)None[source]

Deletes a firewall rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • firewall_rule_name (str) – The name of the firewall rule.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, firewall_rule_name: str, **kwargs: Any) → ’models.FirewallRule’[source]

Gets a firewall rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • firewall_rule_name (str) – The name of the firewall rule.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

FirewallRule, or the result of cls(response)

Return type

FirewallRule

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.FirewallRuleListResult’][source]

Returns a list of firewall rules.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either FirewallRuleListResult or the result of cls(response)

Return type

ItemPaged[FirewallRuleListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.GeoBackupPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

GeoBackupPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, geo_backup_policy_name: Union[str, ‘models.GeoBackupPolicyName’], parameters: ‘models.GeoBackupPolicy’, **kwargs: Any) → ’models.GeoBackupPolicy’[source]

Updates a database geo backup policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • geo_backup_policy_name (str or GeoBackupPolicyName) – The name of the geo backup policy.

  • parameters (GeoBackupPolicy) – The required parameters for creating or updating the geo backup policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

GeoBackupPolicy, or the result of cls(response)

Return type

GeoBackupPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, geo_backup_policy_name: Union[str, ‘models.GeoBackupPolicyName’], **kwargs: Any) → ’models.GeoBackupPolicy’[source]

Gets a geo backup policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • geo_backup_policy_name (str or GeoBackupPolicyName) – The name of the geo backup policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

GeoBackupPolicy, or the result of cls(response)

Return type

GeoBackupPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.GeoBackupPolicyListResult’][source]

Returns a list of geo backup policies.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either GeoBackupPolicyListResult or the result of cls(response)

Return type

ItemPaged[GeoBackupPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_import_operation(resource_group_name: str, server_name: str, database_name: str, extension_name: Union[str, ‘models.ExtensionName’], parameters: ‘models.ImportExtensionRequest’, **kwargs: Any) → LROPoller[‘models.ImportExportResponse’][source]

Creates an import operation that imports a bacpac into an existing database. The existing database must be empty.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to import into.

  • extension_name (str or ExtensionName) – The name of the operation to perform.

  • parameters (ImportExtensionRequest) – The required parameters for importing a Bacpac into a database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ImportExportResponse or the result of cls(response)

Return type

LROPoller[ImportExportResponse]

Raises

HttpResponseError

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.Database’, **kwargs: Any) → LROPoller[‘models.Database’][source]

Creates a new database or updates an existing database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (Database) – The requested database resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Database or the result of cls(response)

Return type

LROPoller[Database]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes the database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_export(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.ExportRequest’, **kwargs: Any) → LROPoller[‘models.ImportExportResponse’][source]

Exports a database to a bacpac.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to be exported.

  • parameters (ExportRequest) – The required parameters for exporting a database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ImportExportResponse or the result of cls(response)

Return type

LROPoller[ImportExportResponse]

Raises

HttpResponseError

begin_failover(resource_group_name: str, server_name: str, database_name: str, replica_type: Optional[Union[str, ‘models.ReplicaType’]] = None, **kwargs: Any) → LROPoller[None][source]

Failovers a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to failover.

  • replica_type (str or ReplicaType) – The type of replica to be failed over.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_import_method(resource_group_name: str, server_name: str, parameters: ‘models.ImportRequest’, **kwargs: Any) → LROPoller[‘models.ImportExportResponse’][source]

Imports a bacpac into a new database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (ImportRequest) – The required parameters for importing a Bacpac into a database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ImportExportResponse or the result of cls(response)

Return type

LROPoller[ImportExportResponse]

Raises

HttpResponseError

begin_pause(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → LROPoller[‘models.Database’][source]

Pauses a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to be paused.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Database or the result of cls(response)

Return type

LROPoller[Database]

Raises

HttpResponseError

begin_resume(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → LROPoller[‘models.Database’][source]

Resumes a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to be resumed.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Database or the result of cls(response)

Return type

LROPoller[Database]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.DatabaseUpdate’, **kwargs: Any) → LROPoller[‘models.Database’][source]

Updates an existing database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (DatabaseUpdate) – The requested database resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Database or the result of cls(response)

Return type

LROPoller[Database]

Raises

HttpResponseError

begin_upgrade_data_warehouse(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → LROPoller[None][source]

Upgrades a data warehouse.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to be upgraded.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.Database’[source]

Gets a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Database, or the result of cls(response)

Return type

Database

Raises

~azure.core.exceptions.HttpResponseError

list_by_elastic_pool(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.DatabaseListResult’][source]

Gets a list of databases in an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseListResult or the result of cls(response)

Return type

ItemPaged[DatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.DatabaseListResult’][source]

Gets a list of databases.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseListResult or the result of cls(response)

Return type

ItemPaged[DatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_metric_definitions(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.MetricDefinitionListResult’][source]

Returns database metric definitions.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either MetricDefinitionListResult or the result of cls(response)

Return type

ItemPaged[MetricDefinitionListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_metrics(resource_group_name: str, server_name: str, database_name: str, filter: str, **kwargs: Any) → Iterable[‘models.MetricListResult’][source]

Returns database metrics.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • filter (str) – An OData filter expression that describes a subset of metrics to return.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either MetricListResult or the result of cls(response)

Return type

ItemPaged[MetricListResult]

Raises

~azure.core.exceptions.HttpResponseError

rename(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.ResourceMoveDefinition’, **kwargs: Any)None[source]

Renames a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to rename.

  • parameters (ResourceMoveDefinition) – The resource move definition for renaming this database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ElasticPoolsOperations(client, config, serializer, deserializer)[source]

Bases: object

ElasticPoolsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, elastic_pool_name: str, parameters: ‘models.ElasticPool’, **kwargs: Any) → LROPoller[‘models.ElasticPool’][source]

Creates or updates an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

  • parameters (ElasticPool) – The elastic pool parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ElasticPool or the result of cls(response)

Return type

LROPoller[ElasticPool]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_failover(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → LROPoller[None][source]

Failovers an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool to failover.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, elastic_pool_name: str, parameters: ‘models.ElasticPoolUpdate’, **kwargs: Any) → LROPoller[‘models.ElasticPool’][source]

Updates an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

  • parameters (ElasticPoolUpdate) – The elastic pool update parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ElasticPool or the result of cls(response)

Return type

LROPoller[ElasticPool]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → ’models.ElasticPool’[source]

Gets an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ElasticPool, or the result of cls(response)

Return type

ElasticPool

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, skip: Optional[int] = None, **kwargs: Any) → Iterable[‘models.ElasticPoolListResult’][source]

Gets all elastic pools in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • skip (int) – The number of elements in the collection to skip.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ElasticPoolListResult or the result of cls(response)

Return type

ItemPaged[ElasticPoolListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_metric_definitions(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.MetricDefinitionListResult’][source]

Returns elastic pool metric definitions.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either MetricDefinitionListResult or the result of cls(response)

Return type

ItemPaged[MetricDefinitionListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_metrics(resource_group_name: str, server_name: str, elastic_pool_name: str, filter: str, **kwargs: Any) → Iterable[‘models.MetricListResult’][source]

Returns elastic pool metrics.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

  • filter (str) – An OData filter expression that describes a subset of metrics to return.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either MetricListResult or the result of cls(response)

Return type

ItemPaged[MetricListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.RecommendedElasticPoolsOperations(client, config, serializer, deserializer)[source]

Bases: object

RecommendedElasticPoolsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, recommended_elastic_pool_name: str, **kwargs: Any) → ’models.RecommendedElasticPool’[source]

Gets a recommended elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • recommended_elastic_pool_name (str) – The name of the recommended elastic pool to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RecommendedElasticPool, or the result of cls(response)

Return type

RecommendedElasticPool

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.RecommendedElasticPoolListResult’][source]

Returns recommended elastic pools.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RecommendedElasticPoolListResult or the result of cls(response)

Return type

ItemPaged[RecommendedElasticPoolListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_metrics(resource_group_name: str, server_name: str, recommended_elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.RecommendedElasticPoolListMetricsResult’][source]

Returns recommended elastic pool metrics.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • recommended_elastic_pool_name (str) – The name of the recommended elastic pool to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RecommendedElasticPoolListMetricsResult or the result of cls(response)

Return type

ItemPaged[RecommendedElasticPoolListMetricsResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ReplicationLinksOperations(client, config, serializer, deserializer)[source]

Bases: object

ReplicationLinksOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_failover(resource_group_name: str, server_name: str, database_name: str, link_id: str, **kwargs: Any) → LROPoller[None][source]

Sets which replica database is primary by failing over from the current primary replica database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database that has the replication link to be failed over.

  • link_id (str) – The ID of the replication link to be failed over.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_failover_allow_data_loss(resource_group_name: str, server_name: str, database_name: str, link_id: str, **kwargs: Any) → LROPoller[None][source]

Sets which replica database is primary by failing over from the current primary replica database. This operation might result in data loss.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database that has the replication link to be failed over.

  • link_id (str) – The ID of the replication link to be failed over.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

Deletes a database replication link in forced or friendly way.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database that has the replication link to be failed over.

  • link_id (str) – The ID of the replication link to be failed over.

  • parameters (UnlinkParameters) – The required parameters for unlinking replication link.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

delete(resource_group_name: str, server_name: str, database_name: str, link_id: str, **kwargs: Any)None[source]

Deletes a database replication link. Cannot be done during failover.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database that has the replication link to be dropped.

  • link_id (str) – The ID of the replication link to be deleted.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, link_id: str, **kwargs: Any) → ’models.ReplicationLink’[source]

Gets a database replication link.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to get the link for.

  • link_id (str) – The replication link ID to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ReplicationLink, or the result of cls(response)

Return type

ReplicationLink

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ReplicationLinkListResult’][source]

Lists a database’s replication links.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database to retrieve links for.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ReplicationLinkListResult or the result of cls(response)

Return type

ItemPaged[ReplicationLinkListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerCommunicationLinksOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerCommunicationLinksOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, communication_link_name: str, parameters: ‘models.ServerCommunicationLink’, **kwargs: Any) → LROPoller[‘models.ServerCommunicationLink’][source]

Creates a server communication link.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • communication_link_name (str) – The name of the server communication link.

  • parameters (ServerCommunicationLink) – The required parameters for creating a server communication link.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerCommunicationLink or the result of cls(response)

Return type

LROPoller[ServerCommunicationLink]

Raises

HttpResponseError

delete(resource_group_name: str, server_name: str, communication_link_name: str, **kwargs: Any)None[source]

Deletes a server communication link.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • communication_link_name (str) – The name of the server communication link.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, communication_link_name: str, **kwargs: Any) → ’models.ServerCommunicationLink’[source]

Returns a server communication link.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • communication_link_name (str) – The name of the server communication link.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerCommunicationLink, or the result of cls(response)

Return type

ServerCommunicationLink

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerCommunicationLinkListResult’][source]

Gets a list of server communication links.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerCommunicationLinkListResult or the result of cls(response)

Return type

ItemPaged[ServerCommunicationLinkListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServiceObjectivesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServiceObjectivesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, service_objective_name: str, **kwargs: Any) → ’models.ServiceObjective’[source]

Gets a database service objective.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • service_objective_name (str) – The name of the service objective to retrieve.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServiceObjective, or the result of cls(response)

Return type

ServiceObjective

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServiceObjectiveListResult’][source]

Returns database service objectives.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServiceObjectiveListResult or the result of cls(response)

Return type

ItemPaged[ServiceObjectiveListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ElasticPoolActivitiesOperations(client, config, serializer, deserializer)[source]

Bases: object

ElasticPoolActivitiesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_elastic_pool(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.ElasticPoolActivityListResult’][source]

Returns elastic pool activities.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool for which to get the current activity.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ElasticPoolActivityListResult or the result of cls(response)

Return type

ItemPaged[ElasticPoolActivityListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ElasticPoolDatabaseActivitiesOperations(client, config, serializer, deserializer)[source]

Bases: object

ElasticPoolDatabaseActivitiesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_elastic_pool(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.ElasticPoolDatabaseActivityListResult’][source]

Returns activity on databases inside of an elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) – The name of the elastic pool.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ElasticPoolDatabaseActivityListResult or the result of cls(response)

Return type

ItemPaged[ElasticPoolDatabaseActivityListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServiceTierAdvisorsOperations(client, config, serializer, deserializer)[source]

Bases: object

ServiceTierAdvisorsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, database_name: str, service_tier_advisor_name: str, **kwargs: Any) → ’models.ServiceTierAdvisor’[source]

Gets a service tier advisor.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of database.

  • service_tier_advisor_name (str) – The name of service tier advisor.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServiceTierAdvisor, or the result of cls(response)

Return type

ServiceTierAdvisor

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ServiceTierAdvisorListResult’][source]

Returns service tier advisors for specified database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServiceTierAdvisorListResult or the result of cls(response)

Return type

ItemPaged[ServiceTierAdvisorListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.TransparentDataEncryptionsOperations(client, config, serializer, deserializer)[source]

Bases: object

TransparentDataEncryptionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, transparent_data_encryption_name: Union[str, ‘models.TransparentDataEncryptionName’], parameters: ‘models.TransparentDataEncryption’, **kwargs: Any) → ’models.TransparentDataEncryption’[source]

Creates or updates a database’s transparent data encryption configuration.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which setting the transparent data encryption applies.

  • transparent_data_encryption_name (str or TransparentDataEncryptionName) – The name of the transparent data encryption configuration.

  • parameters (TransparentDataEncryption) – The required parameters for creating or updating transparent data encryption.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

TransparentDataEncryption, or the result of cls(response)

Return type

TransparentDataEncryption

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, transparent_data_encryption_name: Union[str, ‘models.TransparentDataEncryptionName’], **kwargs: Any) → ’models.TransparentDataEncryption’[source]

Gets a database’s transparent data encryption configuration.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the transparent data encryption applies.

  • transparent_data_encryption_name (str or TransparentDataEncryptionName) – The name of the transparent data encryption configuration.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

TransparentDataEncryption, or the result of cls(response)

Return type

TransparentDataEncryption

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.TransparentDataEncryptionActivitiesOperations(client, config, serializer, deserializer)[source]

Bases: object

TransparentDataEncryptionActivitiesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_configuration(resource_group_name: str, server_name: str, database_name: str, transparent_data_encryption_name: Union[str, ‘models.TransparentDataEncryptionName’], **kwargs: Any) → Iterable[‘models.TransparentDataEncryptionActivityListResult’][source]

Returns a database’s transparent data encryption operation result.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the transparent data encryption applies.

  • transparent_data_encryption_name (str or TransparentDataEncryptionName) – The name of the transparent data encryption configuration.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either TransparentDataEncryptionActivityListResult or the result of cls(response)

Return type

ItemPaged[TransparentDataEncryptionActivityListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerUsagesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerUsagesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerUsageListResult’][source]

Returns server usages.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerUsageListResult or the result of cls(response)

Return type

ItemPaged[ServerUsageListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseUsagesOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseUsagesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DatabaseUsageListResult’][source]

Returns database usages.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseUsageListResult or the result of cls(response)

Return type

ItemPaged[DatabaseUsageListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseAutomaticTuningOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseAutomaticTuningOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.DatabaseAutomaticTuning’[source]

Gets a database’s automatic tuning.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseAutomaticTuning, or the result of cls(response)

Return type

DatabaseAutomaticTuning

Raises

~azure.core.exceptions.HttpResponseError

update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.DatabaseAutomaticTuning’, **kwargs: Any) → ’models.DatabaseAutomaticTuning’[source]

Update automatic tuning properties for target database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (DatabaseAutomaticTuning) – The requested automatic tuning resource state.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseAutomaticTuning, or the result of cls(response)

Return type

DatabaseAutomaticTuning

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.EncryptionProtectorsOperations(client, config, serializer, deserializer)[source]

Bases: object

EncryptionProtectorsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], parameters: ‘models.EncryptionProtector’, **kwargs: Any) → LROPoller[‘models.EncryptionProtector’][source]

Updates an existing encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be updated.

  • parameters (EncryptionProtector) – The requested encryption protector resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either EncryptionProtector or the result of cls(response)

Return type

LROPoller[EncryptionProtector]

Raises

HttpResponseError

begin_revalidate(resource_group_name: str, server_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], **kwargs: Any) → LROPoller[None][source]

Revalidates an existing encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be updated.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], **kwargs: Any) → ’models.EncryptionProtector’[source]

Gets a server encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

EncryptionProtector, or the result of cls(response)

Return type

EncryptionProtector

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.EncryptionProtectorListResult’][source]

Gets a list of server encryption protectors.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either EncryptionProtectorListResult or the result of cls(response)

Return type

ItemPaged[EncryptionProtectorListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.FailoverGroupsOperations(client, config, serializer, deserializer)[source]

Bases: object

FailoverGroupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, failover_group_name: str, parameters: ‘models.FailoverGroup’, **kwargs: Any) → LROPoller[‘models.FailoverGroup’][source]

Creates or updates a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

  • parameters (FailoverGroup) – The failover group parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either FailoverGroup or the result of cls(response)

Return type

LROPoller[FailoverGroup]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_failover(resource_group_name: str, server_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[‘models.FailoverGroup’][source]

Fails over from the current primary server to this server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either FailoverGroup or the result of cls(response)

Return type

LROPoller[FailoverGroup]

Raises

HttpResponseError

begin_force_failover_allow_data_loss(resource_group_name: str, server_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[‘models.FailoverGroup’][source]

Fails over from the current primary server to this server. This operation might result in data loss.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either FailoverGroup or the result of cls(response)

Return type

LROPoller[FailoverGroup]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, failover_group_name: str, parameters: ‘models.FailoverGroupUpdate’, **kwargs: Any) → LROPoller[‘models.FailoverGroup’][source]

Updates a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

  • parameters (FailoverGroupUpdate) – The failover group parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either FailoverGroup or the result of cls(response)

Return type

LROPoller[FailoverGroup]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, failover_group_name: str, **kwargs: Any) → ’models.FailoverGroup’[source]

Gets a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

FailoverGroup, or the result of cls(response)

Return type

FailoverGroup

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.FailoverGroupListResult’][source]

Lists the failover groups in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server containing the failover group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either FailoverGroupListResult or the result of cls(response)

Return type

ItemPaged[FailoverGroupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.Operations(client, config, serializer, deserializer)[source]

Bases: object

Operations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list(**kwargs: Any) → Iterable[‘models.OperationListResult’][source]

Lists all of the available SQL Rest API operations.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either OperationListResult or the result of cls(response)

Return type

ItemPaged[OperationListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerKeysOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerKeysOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, key_name: str, parameters: ‘models.ServerKey’, **kwargs: Any) → LROPoller[‘models.ServerKey’][source]

Creates or updates a server key.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • key_name (str) – The name of the server key to be operated on (updated or created). The key name is required to be in the format of ‘vault_key_version’. For example, if the keyId is https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, then the server key name should be formatted as: YourVaultName_YourKeyName_01234567890123456789012345678901.

  • parameters (ServerKey) – The requested server key resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerKey or the result of cls(response)

Return type

LROPoller[ServerKey]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, key_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes the server key with the given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • key_name (str) – The name of the server key to be deleted.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, key_name: str, **kwargs: Any) → ’models.ServerKey’[source]

Gets a server key.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • key_name (str) – The name of the server key to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerKey, or the result of cls(response)

Return type

ServerKey

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerKeyListResult’][source]

Gets a list of server keys.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerKeyListResult or the result of cls(response)

Return type

ItemPaged[ServerKeyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.SyncAgentsOperations(client, config, serializer, deserializer)[source]

Bases: object

SyncAgentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, sync_agent_name: str, parameters: ‘models.SyncAgent’, **kwargs: Any) → LROPoller[‘models.SyncAgent’][source]

Creates or updates a sync agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

  • sync_agent_name (str) – The name of the sync agent.

  • parameters (SyncAgent) – The requested sync agent resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either SyncAgent or the result of cls(response)

Return type

LROPoller[SyncAgent]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, sync_agent_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a sync agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

  • sync_agent_name (str) – The name of the sync agent.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

generate_key(resource_group_name: str, server_name: str, sync_agent_name: str, **kwargs: Any) → ’models.SyncAgentKeyProperties’[source]

Generates a sync agent key.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

  • sync_agent_name (str) – The name of the sync agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SyncAgentKeyProperties, or the result of cls(response)

Return type

SyncAgentKeyProperties

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, sync_agent_name: str, **kwargs: Any) → ’models.SyncAgent’[source]

Gets a sync agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

  • sync_agent_name (str) – The name of the sync agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SyncAgent, or the result of cls(response)

Return type

SyncAgent

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.SyncAgentListResult’][source]

Lists sync agents in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncAgentListResult or the result of cls(response)

Return type

ItemPaged[SyncAgentListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_linked_databases(resource_group_name: str, server_name: str, sync_agent_name: str, **kwargs: Any) → Iterable[‘models.SyncAgentLinkedDatabaseListResult’][source]

Lists databases linked to a sync agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server on which the sync agent is hosted.

  • sync_agent_name (str) – The name of the sync agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncAgentLinkedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[SyncAgentLinkedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.SubscriptionUsagesOperations(client, config, serializer, deserializer)[source]

Bases: object

SubscriptionUsagesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(location_name: str, usage_name: str, **kwargs: Any) → ’models.SubscriptionUsage’[source]

Gets a subscription usage metric.

Parameters
  • location_name (str) – The name of the region where the resource is located.

  • usage_name (str) – Name of usage metric to return.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SubscriptionUsage, or the result of cls(response)

Return type

SubscriptionUsage

Raises

~azure.core.exceptions.HttpResponseError

list_by_location(location_name: str, **kwargs: Any) → Iterable[‘models.SubscriptionUsageListResult’][source]

Gets all subscription usage metrics in a given location.

Parameters

location_name (str) – The name of the region where the resource is located.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SubscriptionUsageListResult or the result of cls(response)

Return type

ItemPaged[SubscriptionUsageListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.VirtualClustersOperations(client, config, serializer, deserializer)[source]

Bases: object

VirtualClustersOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_delete(resource_group_name: str, virtual_cluster_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a virtual cluster.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • virtual_cluster_name (str) – The name of the virtual cluster.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, virtual_cluster_name: str, parameters: ‘models.VirtualClusterUpdate’, **kwargs: Any) → LROPoller[‘models.VirtualCluster’][source]

Updates a virtual cluster.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • virtual_cluster_name (str) – The name of the virtual cluster.

  • parameters (VirtualClusterUpdate) – The requested managed instance resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either VirtualCluster or the result of cls(response)

Return type

LROPoller[VirtualCluster]

Raises

HttpResponseError

get(resource_group_name: str, virtual_cluster_name: str, **kwargs: Any) → ’models.VirtualCluster’[source]

Gets a virtual cluster.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • virtual_cluster_name (str) – The name of the virtual cluster.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

VirtualCluster, or the result of cls(response)

Return type

VirtualCluster

Raises

~azure.core.exceptions.HttpResponseError

list(**kwargs: Any) → Iterable[‘models.VirtualClusterListResult’][source]

Gets a list of all virtualClusters in the subscription.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either VirtualClusterListResult or the result of cls(response)

Return type

ItemPaged[VirtualClusterListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group(resource_group_name: str, **kwargs: Any) → Iterable[‘models.VirtualClusterListResult’][source]

Gets a list of virtual clusters in a resource group.

Parameters

resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either VirtualClusterListResult or the result of cls(response)

Return type

ItemPaged[VirtualClusterListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.VirtualNetworkRulesOperations(client, config, serializer, deserializer)[source]

Bases: object

VirtualNetworkRulesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, virtual_network_rule_name: str, parameters: ‘models.VirtualNetworkRule’, **kwargs: Any) → LROPoller[‘models.VirtualNetworkRule’][source]

Creates or updates an existing virtual network rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • virtual_network_rule_name (str) – The name of the virtual network rule.

  • parameters (VirtualNetworkRule) – The requested virtual Network Rule Resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either VirtualNetworkRule or the result of cls(response)

Return type

LROPoller[VirtualNetworkRule]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, virtual_network_rule_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes the virtual network rule with the given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • virtual_network_rule_name (str) – The name of the virtual network rule.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, virtual_network_rule_name: str, **kwargs: Any) → ’models.VirtualNetworkRule’[source]

Gets a virtual network rule.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • virtual_network_rule_name (str) – The name of the virtual network rule.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

VirtualNetworkRule, or the result of cls(response)

Return type

VirtualNetworkRule

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.VirtualNetworkRuleListResult’][source]

Gets a list of virtual network rules in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either VirtualNetworkRuleListResult or the result of cls(response)

Return type

ItemPaged[VirtualNetworkRuleListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ExtendedDatabaseBlobAuditingPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ExtendedDatabaseBlobAuditingPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.ExtendedDatabaseBlobAuditingPolicy’, **kwargs: Any) → ’models.ExtendedDatabaseBlobAuditingPolicy’[source]

Creates or updates an extended database’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (ExtendedDatabaseBlobAuditingPolicy) – The extended database blob auditing policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ExtendedDatabaseBlobAuditingPolicy, or the result of cls(response)

Return type

ExtendedDatabaseBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.ExtendedDatabaseBlobAuditingPolicy’[source]

Gets an extended database’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ExtendedDatabaseBlobAuditingPolicy, or the result of cls(response)

Return type

ExtendedDatabaseBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ExtendedDatabaseBlobAuditingPolicyListResult’][source]

Lists extended auditing settings of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ExtendedDatabaseBlobAuditingPolicyListResult or the result of cls(response)

Return type

ItemPaged[ExtendedDatabaseBlobAuditingPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ExtendedServerBlobAuditingPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ExtendedServerBlobAuditingPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, parameters: ‘models.ExtendedServerBlobAuditingPolicy’, **kwargs: Any) → LROPoller[‘models.ExtendedServerBlobAuditingPolicy’][source]

Creates or updates an extended server’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (ExtendedServerBlobAuditingPolicy) – Properties of extended blob auditing policy.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ExtendedServerBlobAuditingPolicy or the result of cls(response)

Return type

LROPoller[ExtendedServerBlobAuditingPolicy]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, **kwargs: Any) → ’models.ExtendedServerBlobAuditingPolicy’[source]

Gets an extended server’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ExtendedServerBlobAuditingPolicy, or the result of cls(response)

Return type

ExtendedServerBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ExtendedServerBlobAuditingPolicyListResult’][source]

Lists extended auditing settings of a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ExtendedServerBlobAuditingPolicyListResult or the result of cls(response)

Return type

ItemPaged[ExtendedServerBlobAuditingPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerBlobAuditingPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerBlobAuditingPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, parameters: ‘models.ServerBlobAuditingPolicy’, **kwargs: Any) → LROPoller[‘models.ServerBlobAuditingPolicy’][source]

Creates or updates a server’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (ServerBlobAuditingPolicy) – Properties of blob auditing policy.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerBlobAuditingPolicy or the result of cls(response)

Return type

LROPoller[ServerBlobAuditingPolicy]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, **kwargs: Any) → ’models.ServerBlobAuditingPolicy’[source]

Gets a server’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerBlobAuditingPolicy, or the result of cls(response)

Return type

ServerBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerBlobAuditingPolicyListResult’][source]

Lists auditing settings of a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerBlobAuditingPolicyListResult or the result of cls(response)

Return type

ItemPaged[ServerBlobAuditingPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseBlobAuditingPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseBlobAuditingPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.DatabaseBlobAuditingPolicy’, **kwargs: Any) → ’models.DatabaseBlobAuditingPolicy’[source]

Creates or updates a database’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (DatabaseBlobAuditingPolicy) – The database blob auditing policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseBlobAuditingPolicy, or the result of cls(response)

Return type

DatabaseBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.DatabaseBlobAuditingPolicy’[source]

Gets a database’s blob auditing policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseBlobAuditingPolicy, or the result of cls(response)

Return type

DatabaseBlobAuditingPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DatabaseBlobAuditingPolicyListResult’][source]

Lists auditing settings of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseBlobAuditingPolicyListResult or the result of cls(response)

Return type

ItemPaged[DatabaseBlobAuditingPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseVulnerabilityAssessmentRuleBaselinesOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseVulnerabilityAssessmentRuleBaselinesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], parameters: ‘models.DatabaseVulnerabilityAssessmentRuleBaseline’, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentRuleBaseline’[source]

Creates or updates a database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

  • parameters (DatabaseVulnerabilityAssessmentRuleBaseline) – The requested rule baseline resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentRuleBaseline, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentRuleBaseline

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], **kwargs: Any)None[source]

Removes the database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentRuleBaseline’[source]

Gets a database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentRuleBaseline, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentRuleBaseline

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseVulnerabilityAssessmentsOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseVulnerabilityAssessmentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], parameters: ‘models.DatabaseVulnerabilityAssessment’, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessment’[source]

Creates or updates the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • parameters (DatabaseVulnerabilityAssessment) – The requested resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessment, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any)None[source]

Removes the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → ’models.DatabaseVulnerabilityAssessment’[source]

Gets the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessment, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DatabaseVulnerabilityAssessmentListResult’][source]

Lists the vulnerability assessment policies associated with a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database for which the vulnerability assessment policies are defined.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseVulnerabilityAssessmentListResult or the result of cls(response)

Return type

ItemPaged[DatabaseVulnerabilityAssessmentListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobAgentsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobAgentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, parameters: ‘models.JobAgent’, **kwargs: Any) → LROPoller[‘models.JobAgent’][source]

Creates or updates a job agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent to be created or updated.

  • parameters (JobAgent) – The requested job agent resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either JobAgent or the result of cls(response)

Return type

LROPoller[JobAgent]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, job_agent_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a job agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent to be deleted.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, job_agent_name: str, parameters: ‘models.JobAgentUpdate’, **kwargs: Any) → LROPoller[‘models.JobAgent’][source]

Updates a job agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent to be updated.

  • parameters (JobAgentUpdate) – The update to the job agent.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either JobAgent or the result of cls(response)

Return type

LROPoller[JobAgent]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, **kwargs: Any) → ’models.JobAgent’[source]

Gets a job agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobAgent, or the result of cls(response)

Return type

JobAgent

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.JobAgentListResult’][source]

Gets a list of job agents in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobAgentListResult or the result of cls(response)

Return type

ItemPaged[JobAgentListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobCredentialsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobCredentialsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, credential_name: str, parameters: ‘models.JobCredential’, **kwargs: Any) → ’models.JobCredential’[source]

Creates or updates a job credential.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • credential_name (str) – The name of the credential.

  • parameters (JobCredential) – The requested job credential state.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobCredential, or the result of cls(response)

Return type

JobCredential

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, job_agent_name: str, credential_name: str, **kwargs: Any)None[source]

Deletes a job credential.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • credential_name (str) – The name of the credential.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, credential_name: str, **kwargs: Any) → ’models.JobCredential’[source]

Gets a jobs credential.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • credential_name (str) – The name of the credential.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobCredential, or the result of cls(response)

Return type

JobCredential

Raises

~azure.core.exceptions.HttpResponseError

list_by_agent(resource_group_name: str, server_name: str, job_agent_name: str, **kwargs: Any) → Iterable[‘models.JobCredentialListResult’][source]

Gets a list of jobs credentials.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobCredentialListResult or the result of cls(response)

Return type

ItemPaged[JobCredentialListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobExecutionsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobExecutionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, **kwargs: Any) → LROPoller[‘models.JobExecution’][source]

Starts an elastic job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either JobExecution or the result of cls(response)

Return type

LROPoller[JobExecution]

Raises

HttpResponseError

begin_create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, **kwargs: Any) → LROPoller[‘models.JobExecution’][source]

Creates or updates a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The job execution id to create the job execution under.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either JobExecution or the result of cls(response)

Return type

LROPoller[JobExecution]

Raises

HttpResponseError

cancel(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, **kwargs: Any)None[source]

Requests cancellation of a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • job_execution_id (str) – The id of the job execution to cancel.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, **kwargs: Any) → ’models.JobExecution’[source]

Gets a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • job_execution_id (str) – The id of the job execution.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobExecution, or the result of cls(response)

Return type

JobExecution

Raises

~azure.core.exceptions.HttpResponseError

list_by_agent(resource_group_name: str, server_name: str, job_agent_name: str, create_time_min: Optional[datetime.datetime] = None, create_time_max: Optional[datetime.datetime] = None, end_time_min: Optional[datetime.datetime] = None, end_time_max: Optional[datetime.datetime] = None, is_active: Optional[bool] = None, skip: Optional[int] = None, top: Optional[int] = None, **kwargs: Any) → Iterable[‘models.JobExecutionListResult’][source]

Lists all executions in a job agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • create_time_min (datetime) – If specified, only job executions created at or after the specified time are included.

  • create_time_max (datetime) – If specified, only job executions created before the specified time are included.

  • end_time_min (datetime) – If specified, only job executions completed at or after the specified time are included.

  • end_time_max (datetime) – If specified, only job executions completed before the specified time are included.

  • is_active (bool) – If specified, only active or only completed job executions are included.

  • skip (int) – The number of elements in the collection to skip.

  • top (int) – The number of elements to return from the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobExecutionListResult or the result of cls(response)

Return type

ItemPaged[JobExecutionListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_job(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, create_time_min: Optional[datetime.datetime] = None, create_time_max: Optional[datetime.datetime] = None, end_time_min: Optional[datetime.datetime] = None, end_time_max: Optional[datetime.datetime] = None, is_active: Optional[bool] = None, skip: Optional[int] = None, top: Optional[int] = None, **kwargs: Any) → Iterable[‘models.JobExecutionListResult’][source]

Lists a job’s executions.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • create_time_min (datetime) – If specified, only job executions created at or after the specified time are included.

  • create_time_max (datetime) – If specified, only job executions created before the specified time are included.

  • end_time_min (datetime) – If specified, only job executions completed at or after the specified time are included.

  • end_time_max (datetime) – If specified, only job executions completed before the specified time are included.

  • is_active (bool) – If specified, only active or only completed job executions are included.

  • skip (int) – The number of elements in the collection to skip.

  • top (int) – The number of elements to return from the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobExecutionListResult or the result of cls(response)

Return type

ItemPaged[JobExecutionListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, parameters: ‘models.Job’, **kwargs: Any) → ’models.Job’[source]

Creates or updates a job.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • parameters (Job) – The requested job state.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Job, or the result of cls(response)

Return type

Job

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, **kwargs: Any)None[source]

Deletes a job.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to delete.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, **kwargs: Any) → ’models.Job’[source]

Gets a job.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Job, or the result of cls(response)

Return type

Job

Raises

~azure.core.exceptions.HttpResponseError

list_by_agent(resource_group_name: str, server_name: str, job_agent_name: str, **kwargs: Any) → Iterable[‘models.JobListResult’][source]

Gets a list of jobs.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobListResult or the result of cls(response)

Return type

ItemPaged[JobListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobStepExecutionsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobStepExecutionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, step_name: str, **kwargs: Any) → ’models.JobExecution’[source]

Gets a step execution of a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The unique id of the job execution.

  • step_name (str) – The name of the step.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobExecution, or the result of cls(response)

Return type

JobExecution

Raises

~azure.core.exceptions.HttpResponseError

list_by_job_execution(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, create_time_min: Optional[datetime.datetime] = None, create_time_max: Optional[datetime.datetime] = None, end_time_min: Optional[datetime.datetime] = None, end_time_max: Optional[datetime.datetime] = None, is_active: Optional[bool] = None, skip: Optional[int] = None, top: Optional[int] = None, **kwargs: Any) → Iterable[‘models.JobExecutionListResult’][source]

Lists the step executions of a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The id of the job execution.

  • create_time_min (datetime) – If specified, only job executions created at or after the specified time are included.

  • create_time_max (datetime) – If specified, only job executions created before the specified time are included.

  • end_time_min (datetime) – If specified, only job executions completed at or after the specified time are included.

  • end_time_max (datetime) – If specified, only job executions completed before the specified time are included.

  • is_active (bool) – If specified, only active or only completed job executions are included.

  • skip (int) – The number of elements in the collection to skip.

  • top (int) – The number of elements to return from the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobExecutionListResult or the result of cls(response)

Return type

ItemPaged[JobExecutionListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobStepsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobStepsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, step_name: str, parameters: ‘models.JobStep’, **kwargs: Any) → ’models.JobStep’[source]

Creates or updates a job step. This will implicitly create a new job version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • step_name (str) – The name of the job step.

  • parameters (JobStep) – The requested state of the job step.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobStep, or the result of cls(response)

Return type

JobStep

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, step_name: str, **kwargs: Any)None[source]

Deletes a job step. This will implicitly create a new job version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • step_name (str) – The name of the job step to delete.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, step_name: str, **kwargs: Any) → ’models.JobStep’[source]

Gets a job step in a job’s current version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • step_name (str) – The name of the job step.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobStep, or the result of cls(response)

Return type

JobStep

Raises

~azure.core.exceptions.HttpResponseError

get_by_version(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_version: int, step_name: str, **kwargs: Any) → ’models.JobStep’[source]

Gets the specified version of a job step.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • job_version (int) – The version of the job to get.

  • step_name (str) – The name of the job step.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobStep, or the result of cls(response)

Return type

JobStep

Raises

~azure.core.exceptions.HttpResponseError

list_by_job(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, **kwargs: Any) → Iterable[‘models.JobStepListResult’][source]

Gets all job steps for a job’s current version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobStepListResult or the result of cls(response)

Return type

ItemPaged[JobStepListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_version(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_version: int, **kwargs: Any) → Iterable[‘models.JobStepListResult’][source]

Gets all job steps in the specified job version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_version (int) – The version of the job to get.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobStepListResult or the result of cls(response)

Return type

ItemPaged[JobStepListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobTargetExecutionsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobTargetExecutionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, step_name: str, target_id: str, **kwargs: Any) → ’models.JobExecution’[source]

Gets a target execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The unique id of the job execution.

  • step_name (str) – The name of the step.

  • target_id (str) – The target id.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobExecution, or the result of cls(response)

Return type

JobExecution

Raises

~azure.core.exceptions.HttpResponseError

list_by_job_execution(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, create_time_min: Optional[datetime.datetime] = None, create_time_max: Optional[datetime.datetime] = None, end_time_min: Optional[datetime.datetime] = None, end_time_max: Optional[datetime.datetime] = None, is_active: Optional[bool] = None, skip: Optional[int] = None, top: Optional[int] = None, **kwargs: Any) → Iterable[‘models.JobExecutionListResult’][source]

Lists target executions for all steps of a job execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The id of the job execution.

  • create_time_min (datetime) – If specified, only job executions created at or after the specified time are included.

  • create_time_max (datetime) – If specified, only job executions created before the specified time are included.

  • end_time_min (datetime) – If specified, only job executions completed at or after the specified time are included.

  • end_time_max (datetime) – If specified, only job executions completed before the specified time are included.

  • is_active (bool) – If specified, only active or only completed job executions are included.

  • skip (int) – The number of elements in the collection to skip.

  • top (int) – The number of elements to return from the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobExecutionListResult or the result of cls(response)

Return type

ItemPaged[JobExecutionListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_step(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_execution_id: str, step_name: str, create_time_min: Optional[datetime.datetime] = None, create_time_max: Optional[datetime.datetime] = None, end_time_min: Optional[datetime.datetime] = None, end_time_max: Optional[datetime.datetime] = None, is_active: Optional[bool] = None, skip: Optional[int] = None, top: Optional[int] = None, **kwargs: Any) → Iterable[‘models.JobExecutionListResult’][source]

Lists the target executions of a job step execution.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

  • job_execution_id (str) – The id of the job execution.

  • step_name (str) – The name of the step.

  • create_time_min (datetime) – If specified, only job executions created at or after the specified time are included.

  • create_time_max (datetime) – If specified, only job executions created before the specified time are included.

  • end_time_min (datetime) – If specified, only job executions completed at or after the specified time are included.

  • end_time_max (datetime) – If specified, only job executions completed before the specified time are included.

  • is_active (bool) – If specified, only active or only completed job executions are included.

  • skip (int) – The number of elements in the collection to skip.

  • top (int) – The number of elements to return from the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobExecutionListResult or the result of cls(response)

Return type

ItemPaged[JobExecutionListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobTargetGroupsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobTargetGroupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, job_agent_name: str, target_group_name: str, parameters: ‘models.JobTargetGroup’, **kwargs: Any) → ’models.JobTargetGroup’[source]

Creates or updates a target group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • target_group_name (str) – The name of the target group.

  • parameters (JobTargetGroup) – The requested state of the target group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobTargetGroup, or the result of cls(response)

Return type

JobTargetGroup

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, job_agent_name: str, target_group_name: str, **kwargs: Any)None[source]

Deletes a target group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • target_group_name (str) – The name of the target group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, job_agent_name: str, target_group_name: str, **kwargs: Any) → ’models.JobTargetGroup’[source]

Gets a target group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • target_group_name (str) – The name of the target group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

JobTargetGroup, or the result of cls(response)

Return type

JobTargetGroup

Raises

~azure.core.exceptions.HttpResponseError

list_by_agent(resource_group_name: str, server_name: str, job_agent_name: str, **kwargs: Any) → Iterable[‘models.JobTargetGroupListResult’][source]

Gets all target groups in an agent.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobTargetGroupListResult or the result of cls(response)

Return type

ItemPaged[JobTargetGroupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.JobVersionsOperations(client, config, serializer, deserializer)[source]

Bases: object

JobVersionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, job_version: int, **kwargs: Any) → ’models.Resource’[source]

Gets a job version.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job.

  • job_version (int) – The version of the job to get.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Resource, or the result of cls(response)

Return type

Resource

Raises

~azure.core.exceptions.HttpResponseError

list_by_job(resource_group_name: str, server_name: str, job_agent_name: str, job_name: str, **kwargs: Any) → Iterable[‘models.JobVersionListResult’][source]

Gets all versions of a job.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • job_agent_name (str) – The name of the job agent.

  • job_name (str) – The name of the job to get.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either JobVersionListResult or the result of cls(response)

Return type

ItemPaged[JobVersionListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.LongTermRetentionBackupsOperations(client, config, serializer, deserializer)[source]

Bases: object

LongTermRetentionBackupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_delete(location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, backup_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a long term retention backup.

Parameters
  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • backup_name (str) – The backup name.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_delete_by_resource_group(resource_group_name: str, location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, backup_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a long term retention backup.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • backup_name (str) – The backup name.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, backup_name: str, **kwargs: Any) → ’models.LongTermRetentionBackup’[source]

Gets a long term retention backup.

Parameters
  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • backup_name (str) – The backup name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

LongTermRetentionBackup, or the result of cls(response)

Return type

LongTermRetentionBackup

Raises

~azure.core.exceptions.HttpResponseError

get_by_resource_group(resource_group_name: str, location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, backup_name: str, **kwargs: Any) → ’models.LongTermRetentionBackup’[source]

Gets a long term retention backup.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • backup_name (str) – The backup name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

LongTermRetentionBackup, or the result of cls(response)

Return type

LongTermRetentionBackup

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists all long term retention backups for a database.

Parameters
  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_location(location_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given location.

Parameters
  • location_name (str) – The location of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_database(resource_group_name: str, location_name: str, long_term_retention_server_name: str, long_term_retention_database_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists all long term retention backups for a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • long_term_retention_database_name (str) – The name of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_location(resource_group_name: str, location_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given location.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_server(resource_group_name: str, location_name: str, long_term_retention_server_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(location_name: str, long_term_retention_server_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.LongTermRetentionDatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.LongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given server.

Parameters
  • location_name (str) – The location of the database.

  • long_term_retention_server_name (str) – The name of the server.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or LongTermRetentionDatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[LongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.BackupLongTermRetentionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

BackupLongTermRetentionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, policy_name: Union[str, ‘models.LongTermRetentionPolicyName’], parameters: ‘models.BackupLongTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.BackupLongTermRetentionPolicy’][source]

Sets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • policy_name (str or LongTermRetentionPolicyName) – The policy name. Should always be Default.

  • parameters (BackupLongTermRetentionPolicy) – The long term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either BackupLongTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[BackupLongTermRetentionPolicy]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, policy_name: Union[str, ‘models.LongTermRetentionPolicyName’], **kwargs: Any) → ’models.BackupLongTermRetentionPolicy’[source]

Gets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • policy_name (str or LongTermRetentionPolicyName) – The policy name. Should always be Default.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

BackupLongTermRetentionPolicy, or the result of cls(response)

Return type

BackupLongTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → ’models.BackupLongTermRetentionPolicy’[source]

Gets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

BackupLongTermRetentionPolicy, or the result of cls(response)

Return type

BackupLongTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedBackupShortTermRetentionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedBackupShortTermRetentionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], parameters: ‘models.ManagedBackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedBackupShortTermRetentionPolicy’][source]

Updates a managed database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (ManagedBackupShortTermRetentionPolicy) – The short term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedBackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[ManagedBackupShortTermRetentionPolicy]

Raises

HttpResponseError

begin_update(resource_group_name: str, managed_instance_name: str, database_name: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], parameters: ‘models.ManagedBackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedBackupShortTermRetentionPolicy’][source]

Updates a managed database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (ManagedBackupShortTermRetentionPolicy) – The short term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedBackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[ManagedBackupShortTermRetentionPolicy]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], **kwargs: Any) → ’models.ManagedBackupShortTermRetentionPolicy’[source]

Gets a managed database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedBackupShortTermRetentionPolicy, or the result of cls(response)

Return type

ManagedBackupShortTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ManagedBackupShortTermRetentionPolicyListResult’][source]

Gets a managed database’s short term retention policy list.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedBackupShortTermRetentionPolicyListResult or the result of cls(response)

Return type

ItemPaged[ManagedBackupShortTermRetentionPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedRestorableDroppedDatabaseBackupShortTermRetentionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedRestorableDroppedDatabaseBackupShortTermRetentionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, restorable_dropped_database_id: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], parameters: ‘models.ManagedBackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedBackupShortTermRetentionPolicy’][source]

Sets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • restorable_dropped_database_id (str) –

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (ManagedBackupShortTermRetentionPolicy) – The long term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedBackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[ManagedBackupShortTermRetentionPolicy]

Raises

HttpResponseError

begin_update(resource_group_name: str, managed_instance_name: str, restorable_dropped_database_id: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], parameters: ‘models.ManagedBackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedBackupShortTermRetentionPolicy’][source]

Sets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • restorable_dropped_database_id (str) –

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (ManagedBackupShortTermRetentionPolicy) – The long term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedBackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[ManagedBackupShortTermRetentionPolicy]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, restorable_dropped_database_id: str, policy_name: Union[str, ‘models.ManagedShortTermRetentionPolicyName’], **kwargs: Any) → ’models.ManagedBackupShortTermRetentionPolicy’[source]

Gets a dropped database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • restorable_dropped_database_id (str) –

  • policy_name (str or ManagedShortTermRetentionPolicyName) – The policy name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedBackupShortTermRetentionPolicy, or the result of cls(response)

Return type

ManagedBackupShortTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_restorable_dropped_database(resource_group_name: str, managed_instance_name: str, restorable_dropped_database_id: str, **kwargs: Any) → Iterable[‘models.ManagedBackupShortTermRetentionPolicyListResult’][source]

Gets a dropped database’s short term retention policy list.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • restorable_dropped_database_id (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedBackupShortTermRetentionPolicyListResult or the result of cls(response)

Return type

ItemPaged[ManagedBackupShortTermRetentionPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerAutomaticTuningOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerAutomaticTuningOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, **kwargs: Any) → ’models.ServerAutomaticTuning’[source]

Retrieves server automatic tuning options.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerAutomaticTuning, or the result of cls(response)

Return type

ServerAutomaticTuning

Raises

~azure.core.exceptions.HttpResponseError

update(resource_group_name: str, server_name: str, parameters: ‘models.ServerAutomaticTuning’, **kwargs: Any) → ’models.ServerAutomaticTuning’[source]

Update automatic tuning options on server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (ServerAutomaticTuning) – The requested automatic tuning resource state.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerAutomaticTuning, or the result of cls(response)

Return type

ServerAutomaticTuning

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerDnsAliasesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerDnsAliasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_acquire(resource_group_name: str, server_name: str, dns_alias_name: str, parameters: ‘models.ServerDnsAliasAcquisition’, **kwargs: Any) → LROPoller[None][source]

Acquires server DNS alias from another server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server that the alias is pointing to.

  • dns_alias_name (str) – The name of the server dns alias.

  • parameters (ServerDnsAliasAcquisition) –

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_create_or_update(resource_group_name: str, server_name: str, dns_alias_name: str, **kwargs: Any) → LROPoller[‘models.ServerDnsAlias’][source]

Creates a server dns alias.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server that the alias is pointing to.

  • dns_alias_name (str) – The name of the server DNS alias.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerDnsAlias or the result of cls(response)

Return type

LROPoller[ServerDnsAlias]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, dns_alias_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes the server DNS alias with the given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server that the alias is pointing to.

  • dns_alias_name (str) – The name of the server DNS alias.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, dns_alias_name: str, **kwargs: Any) → ’models.ServerDnsAlias’[source]

Gets a server DNS alias.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server that the alias is pointing to.

  • dns_alias_name (str) – The name of the server DNS alias.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerDnsAlias, or the result of cls(response)

Return type

ServerDnsAlias

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerDnsAliasListResult’][source]

Gets a list of server DNS aliases for a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server that the alias is pointing to.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerDnsAliasListResult or the result of cls(response)

Return type

ItemPaged[ServerDnsAliasListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerSecurityAlertPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerSecurityAlertPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyNameAutoGenerated’], parameters: ‘models.ServerSecurityAlertPolicy’, **kwargs: Any) → LROPoller[‘models.ServerSecurityAlertPolicy’][source]

Creates or updates a threat detection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • security_alert_policy_name (str or SecurityAlertPolicyNameAutoGenerated) – The name of the threat detection policy.

  • parameters (ServerSecurityAlertPolicy) – The server security alert policy.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerSecurityAlertPolicy or the result of cls(response)

Return type

LROPoller[ServerSecurityAlertPolicy]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyNameAutoGenerated’], **kwargs: Any) → ’models.ServerSecurityAlertPolicy’[source]

Get a server’s security alert policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • security_alert_policy_name (str or SecurityAlertPolicyNameAutoGenerated) – The name of the security alert policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerSecurityAlertPolicy, or the result of cls(response)

Return type

ServerSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.LogicalServerSecurityAlertPolicyListResult’][source]

Get the server’s threat detection policies.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either LogicalServerSecurityAlertPolicyListResult or the result of cls(response)

Return type

ItemPaged[LogicalServerSecurityAlertPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.RestorableDroppedManagedDatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

RestorableDroppedManagedDatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, managed_instance_name: str, restorable_dropped_database_id: str, **kwargs: Any) → ’models.RestorableDroppedManagedDatabase’[source]

Gets a restorable dropped managed database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • restorable_dropped_database_id (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RestorableDroppedManagedDatabase, or the result of cls(response)

Return type

RestorableDroppedManagedDatabase

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.RestorableDroppedManagedDatabaseListResult’][source]

Gets a list of restorable dropped managed databases.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RestorableDroppedManagedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[RestorableDroppedManagedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.RestorePointsOperations(client, config, serializer, deserializer)[source]

Bases: object

RestorePointsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create(resource_group_name: str, server_name: str, database_name: str, parameters: ‘models.CreateDatabaseRestorePointDefinition’, **kwargs: Any) → LROPoller[‘models.RestorePoint’][source]

Creates a restore point for a data warehouse.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • parameters (CreateDatabaseRestorePointDefinition) – The definition for creating the restore point of this database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either RestorePoint or the result of cls(response)

Return type

LROPoller[RestorePoint]

Raises

HttpResponseError

delete(resource_group_name: str, server_name: str, database_name: str, restore_point_name: str, **kwargs: Any)None[source]

Deletes a restore point.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • restore_point_name (str) – The name of the restore point.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, restore_point_name: str, **kwargs: Any) → ’models.RestorePoint’[source]

Gets a restore point.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • restore_point_name (str) – The name of the restore point.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RestorePoint, or the result of cls(response)

Return type

RestorePoint

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.RestorePointListResult’][source]

Gets a list of database restore points.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RestorePointListResult or the result of cls(response)

Return type

ItemPaged[RestorePointListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseSecurityAlertPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseSecurityAlertPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyName’], parameters: ‘models.ManagedDatabaseSecurityAlertPolicy’, **kwargs: Any) → ’models.ManagedDatabaseSecurityAlertPolicy’[source]

Creates or updates a database’s security alert policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database for which the security alert policy is defined.

  • security_alert_policy_name (str or SecurityAlertPolicyName) – The name of the security alert policy.

  • parameters (ManagedDatabaseSecurityAlertPolicy) – The database security alert policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedDatabaseSecurityAlertPolicy, or the result of cls(response)

Return type

ManagedDatabaseSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyName’], **kwargs: Any) → ’models.ManagedDatabaseSecurityAlertPolicy’[source]

Gets a managed database’s security alert policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database for which the security alert policy is defined.

  • security_alert_policy_name (str or SecurityAlertPolicyName) – The name of the security alert policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedDatabaseSecurityAlertPolicy, or the result of cls(response)

Return type

ManagedDatabaseSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ManagedDatabaseSecurityAlertPolicyListResult’][source]

Gets a list of managed database’s security alert policies.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database for which the security alert policies are defined.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedDatabaseSecurityAlertPolicyListResult or the result of cls(response)

Return type

ItemPaged[ManagedDatabaseSecurityAlertPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedServerSecurityAlertPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedServerSecurityAlertPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyNameAutoGenerated’], parameters: ‘models.ManagedServerSecurityAlertPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedServerSecurityAlertPolicy’][source]

Creates or updates a threat detection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • security_alert_policy_name (str or SecurityAlertPolicyNameAutoGenerated) – The name of the security alert policy.

  • parameters (ManagedServerSecurityAlertPolicy) – The managed server security alert policy.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedServerSecurityAlertPolicy or the result of cls(response)

Return type

LROPoller[ManagedServerSecurityAlertPolicy]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, security_alert_policy_name: Union[str, ‘models.SecurityAlertPolicyNameAutoGenerated’], **kwargs: Any) → ’models.ManagedServerSecurityAlertPolicy’[source]

Get a managed server’s threat detection policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • security_alert_policy_name (str or SecurityAlertPolicyNameAutoGenerated) – The name of the security alert policy.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedServerSecurityAlertPolicy, or the result of cls(response)

Return type

ManagedServerSecurityAlertPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedServerSecurityAlertPolicyListResult’][source]

Get the managed server’s threat detection policies.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedServerSecurityAlertPolicyListResult or the result of cls(response)

Return type

ItemPaged[ManagedServerSecurityAlertPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.SensitivityLabelsOperations(client, config, serializer, deserializer)[source]

Bases: object

SensitivityLabelsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, parameters: ‘models.SensitivityLabel’, **kwargs: Any) → ’models.SensitivityLabel’[source]

Creates or updates the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

  • parameters (SensitivityLabel) – The column sensitivity label resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SensitivityLabel, or the result of cls(response)

Return type

SensitivityLabel

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Deletes the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

disable_recommendation(resource_group_name: str, server_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Disables sensitivity recommendations on a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

enable_recommendation(resource_group_name: str, server_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Enables sensitivity recommendations on a given column (recommendations are enabled by default on all columns).

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, sensitivity_label_source: Union[str, ‘models.SensitivityLabelSource’], **kwargs: Any) → ’models.SensitivityLabel’[source]

Gets the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

  • sensitivity_label_source (str or SensitivityLabelSource) – The source of the sensitivity label.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SensitivityLabel, or the result of cls(response)

Return type

SensitivityLabel

Raises

~azure.core.exceptions.HttpResponseError

list_current_by_database(resource_group_name: str, server_name: str, database_name: str, filter: Optional[str] = None, **kwargs: Any) → Iterable[‘models.SensitivityLabelListResult’][source]

Gets the sensitivity labels of a given database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • filter (str) – An OData filter expression that filters elements in the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SensitivityLabelListResult or the result of cls(response)

Return type

ItemPaged[SensitivityLabelListResult]

Raises

~azure.core.exceptions.HttpResponseError

Gets the sensitivity labels of a given database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • include_disabled_recommendations (bool) – Specifies whether to include disabled recommendations or not.

  • skip_token (str) –

  • filter (str) – An OData filter expression that filters elements in the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SensitivityLabelListResult or the result of cls(response)

Return type

ItemPaged[SensitivityLabelListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceAdministratorsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceAdministratorsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, parameters: ‘models.ManagedInstanceAdministrator’, **kwargs: Any) → LROPoller[‘models.ManagedInstanceAdministrator’][source]

Creates or updates a managed instance administrator.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • parameters (ManagedInstanceAdministrator) – The requested administrator parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstanceAdministrator or the result of cls(response)

Return type

LROPoller[ManagedInstanceAdministrator]

Raises

HttpResponseError

begin_delete(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a managed instance administrator.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → ’models.ManagedInstanceAdministrator’[source]

Gets a managed instance administrator.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceAdministrator, or the result of cls(response)

Return type

ManagedInstanceAdministrator

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceAdministratorListResult’][source]

Gets a list of managed instance administrators.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceAdministratorListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceAdministratorListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseOperationsOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseOperationsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

cancel(resource_group_name: str, server_name: str, database_name: str, operation_id: str, **kwargs: Any)None[source]

Cancels the asynchronous operation on the database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • operation_id (str) – The operation identifier.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DatabaseOperationListResult’][source]

Gets a list of operations performed on the database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseOperationListResult or the result of cls(response)

Return type

ItemPaged[DatabaseOperationListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ElasticPoolOperationsOperations(client, config, serializer, deserializer)[source]

Bases: object

ElasticPoolOperationsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

cancel(resource_group_name: str, server_name: str, elastic_pool_name: str, operation_id: str, **kwargs: Any)None[source]

Cancels the asynchronous operation on the elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) –

  • operation_id (str) – The operation identifier.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

list_by_elastic_pool(resource_group_name: str, server_name: str, elastic_pool_name: str, **kwargs: Any) → Iterable[‘models.ElasticPoolOperationListResult’][source]

Gets a list of operations performed on the elastic pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • elastic_pool_name (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ElasticPoolOperationListResult or the result of cls(response)

Return type

ItemPaged[ElasticPoolOperationListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.DatabaseVulnerabilityAssessmentScansOperations(client, config, serializer, deserializer)[source]

Bases: object

DatabaseVulnerabilityAssessmentScansOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_initiate_scan(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → LROPoller[None][source]

Executes a Vulnerability Assessment database scan.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id of the scan to retrieve.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

export(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentScansExport’[source]

Convert an existing scan result to a human readable format. If already exists nothing happens.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the scanned database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentScansExport, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentScansExport

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → ’models.VulnerabilityAssessmentScanRecord’[source]

Gets a vulnerability assessment scan record of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id of the scan to retrieve.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

VulnerabilityAssessmentScanRecord, or the result of cls(response)

Return type

VulnerabilityAssessmentScanRecord

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → Iterable[‘models.VulnerabilityAssessmentScanRecordListResult’][source]

Lists the vulnerability assessment scans of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either VulnerabilityAssessmentScanRecordListResult or the result of cls(response)

Return type

ItemPaged[VulnerabilityAssessmentScanRecordListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseVulnerabilityAssessmentRuleBaselinesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseVulnerabilityAssessmentRuleBaselinesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], parameters: ‘models.DatabaseVulnerabilityAssessmentRuleBaseline’, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentRuleBaseline’[source]

Creates or updates a database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

  • parameters (DatabaseVulnerabilityAssessmentRuleBaseline) – The requested rule baseline resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentRuleBaseline, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentRuleBaseline

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], **kwargs: Any)None[source]

Removes the database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], rule_id: str, baseline_name: Union[str, ‘models.VulnerabilityAssessmentPolicyBaselineName’], **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentRuleBaseline’[source]

Gets a database’s vulnerability assessment rule baseline.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment rule baseline is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • rule_id (str) – The vulnerability assessment rule ID.

  • baseline_name (str or VulnerabilityAssessmentPolicyBaselineName) – The name of the vulnerability assessment rule baseline (default implies a baseline on a database level rule and master for server level rule).

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentRuleBaseline, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentRuleBaseline

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseVulnerabilityAssessmentScansOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseVulnerabilityAssessmentScansOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_initiate_scan(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → LROPoller[None][source]

Executes a Vulnerability Assessment database scan.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id of the scan to retrieve.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

export(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessmentScansExport’[source]

Convert an existing scan result to a human readable format. If already exists nothing happens.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the scanned database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessmentScansExport, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessmentScansExport

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], scan_id: str, **kwargs: Any) → ’models.VulnerabilityAssessmentScanRecord’[source]

Gets a vulnerability assessment scan record of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • scan_id (str) – The vulnerability assessment scan Id of the scan to retrieve.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

VulnerabilityAssessmentScanRecord, or the result of cls(response)

Return type

VulnerabilityAssessmentScanRecord

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → Iterable[‘models.VulnerabilityAssessmentScanRecordListResult’][source]

Lists the vulnerability assessment scans of a database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either VulnerabilityAssessmentScanRecordListResult or the result of cls(response)

Return type

ItemPaged[VulnerabilityAssessmentScanRecordListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseVulnerabilityAssessmentsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseVulnerabilityAssessmentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], parameters: ‘models.DatabaseVulnerabilityAssessment’, **kwargs: Any) → ’models.DatabaseVulnerabilityAssessment’[source]

Creates or updates the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • parameters (DatabaseVulnerabilityAssessment) – The requested resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessment, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any)None[source]

Removes the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → ’models.DatabaseVulnerabilityAssessment’[source]

Gets the database’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

DatabaseVulnerabilityAssessment, or the result of cls(response)

Return type

DatabaseVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.DatabaseVulnerabilityAssessmentListResult’][source]

Lists the vulnerability assessments of a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database for which the vulnerability assessment is defined.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either DatabaseVulnerabilityAssessmentListResult or the result of cls(response)

Return type

ItemPaged[DatabaseVulnerabilityAssessmentListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.InstanceFailoverGroupsOperations(client, config, serializer, deserializer)[source]

Bases: object

InstanceFailoverGroupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, location_name: str, failover_group_name: str, parameters: ‘models.InstanceFailoverGroup’, **kwargs: Any) → LROPoller[‘models.InstanceFailoverGroup’][source]

Creates or updates a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

  • failover_group_name (str) – The name of the failover group.

  • parameters (InstanceFailoverGroup) – The failover group parameters.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either InstanceFailoverGroup or the result of cls(response)

Return type

LROPoller[InstanceFailoverGroup]

Raises

HttpResponseError

begin_delete(resource_group_name: str, location_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_failover(resource_group_name: str, location_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[‘models.InstanceFailoverGroup’][source]

Fails over from the current primary managed instance to this managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either InstanceFailoverGroup or the result of cls(response)

Return type

LROPoller[InstanceFailoverGroup]

Raises

HttpResponseError

begin_force_failover_allow_data_loss(resource_group_name: str, location_name: str, failover_group_name: str, **kwargs: Any) → LROPoller[‘models.InstanceFailoverGroup’][source]

Fails over from the current primary managed instance to this managed instance. This operation might result in data loss.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either InstanceFailoverGroup or the result of cls(response)

Return type

LROPoller[InstanceFailoverGroup]

Raises

HttpResponseError

get(resource_group_name: str, location_name: str, failover_group_name: str, **kwargs: Any) → ’models.InstanceFailoverGroup’[source]

Gets a failover group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

  • failover_group_name (str) – The name of the failover group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

InstanceFailoverGroup, or the result of cls(response)

Return type

InstanceFailoverGroup

Raises

~azure.core.exceptions.HttpResponseError

list_by_location(resource_group_name: str, location_name: str, **kwargs: Any) → Iterable[‘models.InstanceFailoverGroupListResult’][source]

Lists the failover groups in a location.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The name of the region where the resource is located.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either InstanceFailoverGroupListResult or the result of cls(response)

Return type

ItemPaged[InstanceFailoverGroupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.TdeCertificatesOperations(client, config, serializer, deserializer)[source]

Bases: object

TdeCertificatesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create(resource_group_name: str, server_name: str, parameters: ‘models.TdeCertificate’, **kwargs: Any) → LROPoller[None][source]

Creates a TDE certificate for a given server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (TdeCertificate) – The requested TDE certificate to be created or updated.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceTdeCertificatesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceTdeCertificatesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create(resource_group_name: str, managed_instance_name: str, parameters: ‘models.TdeCertificate’, **kwargs: Any) → LROPoller[None][source]

Creates a TDE certificate for a given server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • parameters (TdeCertificate) – The requested TDE certificate to be created or updated.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceKeysOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceKeysOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, key_name: str, parameters: ‘models.ManagedInstanceKey’, **kwargs: Any) → LROPoller[‘models.ManagedInstanceKey’][source]

Creates or updates a managed instance key.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • key_name (str) – The name of the managed instance key to be operated on (updated or created).

  • parameters (ManagedInstanceKey) – The requested managed instance key resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstanceKey or the result of cls(response)

Return type

LROPoller[ManagedInstanceKey]

Raises

HttpResponseError

begin_delete(resource_group_name: str, managed_instance_name: str, key_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes the managed instance key with the given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • key_name (str) – The name of the managed instance key to be deleted.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, key_name: str, **kwargs: Any) → ’models.ManagedInstanceKey’[source]

Gets a managed instance key.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • key_name (str) – The name of the managed instance key to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceKey, or the result of cls(response)

Return type

ManagedInstanceKey

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, filter: Optional[str] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceKeyListResult’][source]

Gets a list of managed instance keys.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • filter (str) – An OData filter expression that filters elements in the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceKeyListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceKeyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceEncryptionProtectorsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceEncryptionProtectorsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], parameters: ‘models.ManagedInstanceEncryptionProtector’, **kwargs: Any) → LROPoller[‘models.ManagedInstanceEncryptionProtector’][source]

Updates an existing encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be updated.

  • parameters (ManagedInstanceEncryptionProtector) – The requested encryption protector resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstanceEncryptionProtector or the result of cls(response)

Return type

LROPoller[ManagedInstanceEncryptionProtector]

Raises

HttpResponseError

begin_revalidate(resource_group_name: str, managed_instance_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], **kwargs: Any) → LROPoller[None][source]

Revalidates an existing encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be updated.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, encryption_protector_name: Union[str, ‘models.EncryptionProtectorName’], **kwargs: Any) → ’models.ManagedInstanceEncryptionProtector’[source]

Gets a managed instance encryption protector.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • encryption_protector_name (str or EncryptionProtectorName) – The name of the encryption protector to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceEncryptionProtector, or the result of cls(response)

Return type

ManagedInstanceEncryptionProtector

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceEncryptionProtectorListResult’][source]

Gets a list of managed instance encryption protectors.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceEncryptionProtectorListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceEncryptionProtectorListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.RecoverableManagedDatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

RecoverableManagedDatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, managed_instance_name: str, recoverable_database_name: str, **kwargs: Any) → ’models.RecoverableManagedDatabase’[source]

Gets a recoverable managed database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • recoverable_database_name (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

RecoverableManagedDatabase, or the result of cls(response)

Return type

RecoverableManagedDatabase

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.RecoverableManagedDatabaseListResult’][source]

Gets a list of recoverable managed databases.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either RecoverableManagedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[RecoverableManagedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceVulnerabilityAssessmentsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceVulnerabilityAssessmentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, managed_instance_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], parameters: ‘models.ManagedInstanceVulnerabilityAssessment’, **kwargs: Any) → ’models.ManagedInstanceVulnerabilityAssessment’[source]

Creates or updates the managed instance’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • parameters (ManagedInstanceVulnerabilityAssessment) – The requested resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceVulnerabilityAssessment, or the result of cls(response)

Return type

ManagedInstanceVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, managed_instance_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any)None[source]

Removes the managed instance’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → ’models.ManagedInstanceVulnerabilityAssessment’[source]

Gets the managed instance’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceVulnerabilityAssessment, or the result of cls(response)

Return type

ManagedInstanceVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceVulnerabilityAssessmentListResult’][source]

Gets the managed instance’s vulnerability assessment policies.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance for which the vulnerability assessments is defined.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceVulnerabilityAssessmentListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceVulnerabilityAssessmentListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerVulnerabilityAssessmentsOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerVulnerabilityAssessmentsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, server_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], parameters: ‘models.ServerVulnerabilityAssessment’, **kwargs: Any) → ’models.ServerVulnerabilityAssessment’[source]

Creates or updates the server’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

  • parameters (ServerVulnerabilityAssessment) – The requested resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerVulnerabilityAssessment, or the result of cls(response)

Return type

ServerVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, server_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any)None[source]

Removes the server’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, vulnerability_assessment_name: Union[str, ‘models.VulnerabilityAssessmentName’], **kwargs: Any) → ’models.ServerVulnerabilityAssessment’[source]

Gets the server’s vulnerability assessment.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server for which the vulnerability assessment is defined.

  • vulnerability_assessment_name (str or VulnerabilityAssessmentName) – The name of the vulnerability assessment.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerVulnerabilityAssessment, or the result of cls(response)

Return type

ServerVulnerabilityAssessment

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.ServerVulnerabilityAssessmentListResult’][source]

Lists the vulnerability assessment policies associated with a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerVulnerabilityAssessmentListResult or the result of cls(response)

Return type

ItemPaged[ServerVulnerabilityAssessmentListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseSensitivityLabelsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseSensitivityLabelsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, parameters: ‘models.SensitivityLabel’, **kwargs: Any) → ’models.SensitivityLabel’[source]

Creates or updates the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

  • parameters (SensitivityLabel) – The column sensitivity label resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SensitivityLabel, or the result of cls(response)

Return type

SensitivityLabel

Raises

~azure.core.exceptions.HttpResponseError

delete(resource_group_name: str, managed_instance_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Deletes the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

disable_recommendation(resource_group_name: str, managed_instance_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Disables sensitivity recommendations on a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

enable_recommendation(resource_group_name: str, managed_instance_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, **kwargs: Any)None[source]

Enables sensitivity recommendations on a given column (recommendations are enabled by default on all columns).

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, schema_name: str, table_name: str, column_name: str, sensitivity_label_source: Union[str, ‘models.SensitivityLabelSource’], **kwargs: Any) → ’models.SensitivityLabel’[source]

Gets the sensitivity label of a given column.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • schema_name (str) – The name of the schema.

  • table_name (str) – The name of the table.

  • column_name (str) – The name of the column.

  • sensitivity_label_source (str or SensitivityLabelSource) – The source of the sensitivity label.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SensitivityLabel, or the result of cls(response)

Return type

SensitivityLabel

Raises

~azure.core.exceptions.HttpResponseError

list_current_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, filter: Optional[str] = None, **kwargs: Any) → Iterable[‘models.SensitivityLabelListResult’][source]

Gets the sensitivity labels of a given database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • filter (str) – An OData filter expression that filters elements in the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SensitivityLabelListResult or the result of cls(response)

Return type

ItemPaged[SensitivityLabelListResult]

Raises

~azure.core.exceptions.HttpResponseError

Gets the sensitivity labels of a given database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • include_disabled_recommendations (bool) – Specifies whether to include disabled recommendations or not.

  • skip_token (str) –

  • filter (str) – An OData filter expression that filters elements in the collection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SensitivityLabelListResult or the result of cls(response)

Return type

ItemPaged[SensitivityLabelListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.InstancePoolsOperations(client, config, serializer, deserializer)[source]

Bases: object

InstancePoolsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, instance_pool_name: str, parameters: ‘models.InstancePool’, **kwargs: Any) → LROPoller[‘models.InstancePool’][source]

Creates or updates an instance pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The name of the instance pool to be created or updated.

  • parameters (InstancePool) – The requested instance pool resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either InstancePool or the result of cls(response)

Return type

LROPoller[InstancePool]

Raises

HttpResponseError

begin_delete(resource_group_name: str, instance_pool_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes an instance pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The name of the instance pool to be deleted.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, instance_pool_name: str, parameters: ‘models.InstancePoolUpdate’, **kwargs: Any) → LROPoller[‘models.InstancePool’][source]

Updates an instance pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The name of the instance pool to be updated.

  • parameters (InstancePoolUpdate) – The requested instance pool resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either InstancePool or the result of cls(response)

Return type

LROPoller[InstancePool]

Raises

HttpResponseError

get(resource_group_name: str, instance_pool_name: str, **kwargs: Any) → ’models.InstancePool’[source]

Gets an instance pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The name of the instance pool to be retrieved.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

InstancePool, or the result of cls(response)

Return type

InstancePool

Raises

~azure.core.exceptions.HttpResponseError

list(**kwargs: Any) → Iterable[‘models.InstancePoolListResult’][source]

Gets a list of all instance pools in the subscription.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either InstancePoolListResult or the result of cls(response)

Return type

ItemPaged[InstancePoolListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group(resource_group_name: str, **kwargs: Any) → Iterable[‘models.InstancePoolListResult’][source]

Gets a list of instance pools in the resource group.

Parameters

resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either InstancePoolListResult or the result of cls(response)

Return type

ItemPaged[InstancePoolListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.UsagesOperations(client, config, serializer, deserializer)[source]

Bases: object

UsagesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_instance_pool(resource_group_name: str, instance_pool_name: str, expand_children: Optional[bool] = None, **kwargs: Any) → Iterable[‘models.UsageListResult’][source]

Gets all instance pool usage metrics.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The name of the instance pool to be retrieved.

  • expand_children (bool) – Optional request parameter to include managed instance usages within the instance pool.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either UsageListResult or the result of cls(response)

Return type

ItemPaged[UsageListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.PrivateEndpointConnectionsOperations(client, config, serializer, deserializer)[source]

Bases: object

PrivateEndpointConnectionsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, private_endpoint_connection_name: str, parameters: ‘models.PrivateEndpointConnection’, **kwargs: Any) → LROPoller[‘models.PrivateEndpointConnection’][source]

Approve or reject a private endpoint connection with a given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • private_endpoint_connection_name (str) –

  • parameters (PrivateEndpointConnection) –

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either PrivateEndpointConnection or the result of cls(response)

Return type

LROPoller[PrivateEndpointConnection]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, private_endpoint_connection_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a private endpoint connection with a given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • private_endpoint_connection_name (str) –

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, private_endpoint_connection_name: str, **kwargs: Any) → ’models.PrivateEndpointConnection’[source]

Gets a private endpoint connection.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • private_endpoint_connection_name (str) – The name of the private endpoint connection.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

PrivateEndpointConnection, or the result of cls(response)

Return type

PrivateEndpointConnection

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.PrivateEndpointConnectionListResult’][source]

Gets all private endpoint connections on a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either PrivateEndpointConnectionListResult or the result of cls(response)

Return type

ItemPaged[PrivateEndpointConnectionListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.PrivateLinkResourcesOperations(client, config, serializer, deserializer)[source]

Bases: object

PrivateLinkResourcesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, server_name: str, group_name: str, **kwargs: Any) → ’models.PrivateLinkResource’[source]

Gets a private link resource for SQL server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • group_name (str) – The name of the private link resource.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

PrivateLinkResource, or the result of cls(response)

Return type

PrivateLinkResource

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.PrivateLinkResourceListResult’][source]

Gets the private link resources for SQL server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either PrivateLinkResourceListResult or the result of cls(response)

Return type

ItemPaged[PrivateLinkResourceListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServersOperations(client, config, serializer, deserializer)[source]

Bases: object

ServersOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, parameters: ‘models.Server’, **kwargs: Any) → LROPoller[‘models.Server’][source]

Creates or updates a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (Server) – The requested server resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Server or the result of cls(response)

Return type

LROPoller[Server]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, parameters: ‘models.ServerUpdate’, **kwargs: Any) → LROPoller[‘models.Server’][source]

Updates a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • parameters (ServerUpdate) – The requested server resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either Server or the result of cls(response)

Return type

LROPoller[Server]

Raises

HttpResponseError

check_name_availability(parameters: ‘models.CheckNameAvailabilityRequest’, **kwargs: Any) → ’models.CheckNameAvailabilityResponse’[source]

Determines whether a resource can be created with the specified name.

Parameters

parameters (CheckNameAvailabilityRequest) – The name availability request parameters.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

CheckNameAvailabilityResponse, or the result of cls(response)

Return type

CheckNameAvailabilityResponse

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, **kwargs: Any) → ’models.Server’[source]

Gets a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Server, or the result of cls(response)

Return type

Server

Raises

~azure.core.exceptions.HttpResponseError

list(**kwargs: Any) → Iterable[‘models.ServerListResult’][source]

Gets a list of all servers in the subscription.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerListResult or the result of cls(response)

Return type

ItemPaged[ServerListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group(resource_group_name: str, **kwargs: Any) → Iterable[‘models.ServerListResult’][source]

Gets a list of servers in a resource groups.

Parameters

resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ServerListResult or the result of cls(response)

Return type

ItemPaged[ServerListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.CapabilitiesOperations(client, config, serializer, deserializer)[source]

Bases: object

CapabilitiesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

list_by_location(location_name: str, include: Optional[Union[str, ‘models.CapabilityGroup’]] = None, **kwargs: Any) → ’models.LocationCapabilities’[source]

Gets the subscription capabilities available for the specified location.

Parameters
  • location_name (str) – The location name whose capabilities are retrieved.

  • include (str or CapabilityGroup) – If specified, restricts the response to only include the selected item.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

LocationCapabilities, or the result of cls(response)

Return type

LocationCapabilities

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.LongTermRetentionManagedInstanceBackupsOperations(client, config, serializer, deserializer)[source]

Bases: object

LongTermRetentionManagedInstanceBackupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_delete(location_name: str, managed_instance_name: str, database_name: str, backup_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a long term retention backup.

Parameters
  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • backup_name (str) – The backup name.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_delete_by_resource_group(resource_group_name: str, location_name: str, managed_instance_name: str, database_name: str, backup_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a long term retention backup.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • backup_name (str) – The backup name.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(location_name: str, managed_instance_name: str, database_name: str, backup_name: str, **kwargs: Any) → ’models.ManagedInstanceLongTermRetentionBackup’[source]

Gets a long term retention backup for a managed database.

Parameters
  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • backup_name (str) – The backup name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceLongTermRetentionBackup, or the result of cls(response)

Return type

ManagedInstanceLongTermRetentionBackup

Raises

~azure.core.exceptions.HttpResponseError

get_by_resource_group(resource_group_name: str, location_name: str, managed_instance_name: str, database_name: str, backup_name: str, **kwargs: Any) → ’models.ManagedInstanceLongTermRetentionBackup’[source]

Gets a long term retention backup for a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • backup_name (str) – The backup name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceLongTermRetentionBackup, or the result of cls(response)

Return type

ManagedInstanceLongTermRetentionBackup

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(location_name: str, managed_instance_name: str, database_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists all long term retention backups for a managed database.

Parameters
  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(location_name: str, managed_instance_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given managed instance.

Parameters
  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_location(location_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists the long term retention backups for managed databases in a given location.

Parameters
  • location_name (str) – The location of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_database(resource_group_name: str, location_name: str, managed_instance_name: str, database_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists all long term retention backups for a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the managed database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_instance(resource_group_name: str, location_name: str, managed_instance_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists the long term retention backups for a given managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • managed_instance_name (str) – The name of the managed instance.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group_location(resource_group_name: str, location_name: str, only_latest_per_database: Optional[bool] = None, database_state: Optional[Union[str, ‘models.DatabaseState’]] = None, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionBackupListResult’][source]

Lists the long term retention backups for managed databases in a given location.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • location_name (str) – The location of the database.

  • only_latest_per_database (bool) – Whether or not to only get the latest backup for each database.

  • database_state (str or DatabaseState) – Whether to query against just live databases, just deleted databases, or all databases.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionBackupListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionBackupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceLongTermRetentionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceLongTermRetentionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, policy_name: Union[str, ‘models.ManagedInstanceLongTermRetentionPolicyName’], parameters: ‘models.ManagedInstanceLongTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.ManagedInstanceLongTermRetentionPolicy’][source]

Sets a managed database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • policy_name (str or ManagedInstanceLongTermRetentionPolicyName) – The policy name. Should always be Default.

  • parameters (ManagedInstanceLongTermRetentionPolicy) – The long term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstanceLongTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[ManagedInstanceLongTermRetentionPolicy]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, policy_name: Union[str, ‘models.ManagedInstanceLongTermRetentionPolicyName’], **kwargs: Any) → ’models.ManagedInstanceLongTermRetentionPolicy’[source]

Gets a managed database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • policy_name (str or ManagedInstanceLongTermRetentionPolicyName) – The policy name. Should always be Default.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceLongTermRetentionPolicy, or the result of cls(response)

Return type

ManagedInstanceLongTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceLongTermRetentionPolicyListResult’][source]

Gets a database’s long term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceLongTermRetentionPolicyListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceLongTermRetentionPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.WorkloadGroupsOperations(client, config, serializer, deserializer)[source]

Bases: object

WorkloadGroupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, parameters: ‘models.WorkloadGroup’, **kwargs: Any) → LROPoller[‘models.WorkloadGroup’][source]

Creates or updates a workload group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group.

  • parameters (WorkloadGroup) – The requested workload group state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either WorkloadGroup or the result of cls(response)

Return type

LROPoller[WorkloadGroup]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a workload group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group to delete.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, **kwargs: Any) → ’models.WorkloadGroup’[source]

Gets a workload group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

WorkloadGroup, or the result of cls(response)

Return type

WorkloadGroup

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.WorkloadGroupListResult’][source]

Gets the list of workload groups.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either WorkloadGroupListResult or the result of cls(response)

Return type

ItemPaged[WorkloadGroupListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.WorkloadClassifiersOperations(client, config, serializer, deserializer)[source]

Bases: object

WorkloadClassifiersOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, workload_classifier_name: str, parameters: ‘models.WorkloadClassifier’, **kwargs: Any) → LROPoller[‘models.WorkloadClassifier’][source]

Creates or updates a workload classifier.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group from which to receive the classifier from.

  • workload_classifier_name (str) – The name of the workload classifier to create/update.

  • parameters (WorkloadClassifier) – The properties of the workload classifier.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either WorkloadClassifier or the result of cls(response)

Return type

LROPoller[WorkloadClassifier]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, workload_classifier_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a workload classifier.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group from which to receive the classifier from.

  • workload_classifier_name (str) – The name of the workload classifier to delete.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, workload_classifier_name: str, **kwargs: Any) → ’models.WorkloadClassifier’[source]

Gets a workload classifier.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group from which to receive the classifier from.

  • workload_classifier_name (str) – The name of the workload classifier.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

WorkloadClassifier, or the result of cls(response)

Return type

WorkloadClassifier

Raises

~azure.core.exceptions.HttpResponseError

list_by_workload_group(resource_group_name: str, server_name: str, database_name: str, workload_group_name: str, **kwargs: Any) → Iterable[‘models.WorkloadClassifierListResult’][source]

Gets the list of workload classifiers for a workload group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • workload_group_name (str) – The name of the workload group from which to receive the classifiers from.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either WorkloadClassifierListResult or the result of cls(response)

Return type

ItemPaged[WorkloadClassifierListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstanceOperationsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstanceOperationsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

cancel(resource_group_name: str, managed_instance_name: str, operation_id: str, **kwargs: Any)None[source]

Cancels the asynchronous operation on the managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • operation_id (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, managed_instance_name: str, operation_id: str, **kwargs: Any) → ’models.ManagedInstanceOperation’[source]

Gets a management operation on a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • operation_id (str) –

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstanceOperation, or the result of cls(response)

Return type

ManagedInstanceOperation

Raises

~azure.core.exceptions.HttpResponseError

list_by_managed_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceOperationListResult’][source]

Gets a list of operations performed on the managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceOperationListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceOperationListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerAzureADAdministratorsOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerAzureADAdministratorsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, administrator_name: Union[str, ‘models.AdministratorName’], parameters: ‘models.ServerAzureADAdministrator’, **kwargs: Any) → LROPoller[‘models.ServerAzureADAdministrator’][source]

Creates or updates an existing Azure Active Directory administrator.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • administrator_name (str or AdministratorName) – The name of server active directory administrator.

  • parameters (ServerAzureADAdministrator) – The requested Azure Active Directory administrator Resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerAzureADAdministrator or the result of cls(response)

Return type

LROPoller[ServerAzureADAdministrator]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, administrator_name: Union[str, ‘models.AdministratorName’], **kwargs: Any) → LROPoller[None][source]

Deletes the Azure Active Directory administrator with the given name.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • administrator_name (str or AdministratorName) – The name of server active directory administrator.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, administrator_name: Union[str, ‘models.AdministratorName’], **kwargs: Any) → ’models.ServerAzureADAdministrator’[source]

Gets a Azure Active Directory administrator.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • administrator_name (str or AdministratorName) – The name of server active directory administrator.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerAzureADAdministrator, or the result of cls(response)

Return type

ServerAzureADAdministrator

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.AdministratorListResult’][source]

Gets a list of Azure Active Directory administrators in a server.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either AdministratorListResult or the result of cls(response)

Return type

ItemPaged[AdministratorListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.SyncGroupsOperations(client, config, serializer, deserializer)[source]

Bases: object

SyncGroupsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, parameters: ‘models.SyncGroup’, **kwargs: Any) → LROPoller[‘models.SyncGroup’][source]

Creates or updates a sync group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

  • parameters (SyncGroup) – The requested sync group resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either SyncGroup or the result of cls(response)

Return type

LROPoller[SyncGroup]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a sync group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_refresh_hub_schema(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any) → LROPoller[None][source]

Refreshes a hub database schema.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, parameters: ‘models.SyncGroup’, **kwargs: Any) → LROPoller[‘models.SyncGroup’][source]

Updates a sync group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

  • parameters (SyncGroup) – The requested sync group resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either SyncGroup or the result of cls(response)

Return type

LROPoller[SyncGroup]

Raises

HttpResponseError

cancel_sync(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any)None[source]

Cancels a sync group synchronization.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any) → ’models.SyncGroup’[source]

Gets a sync group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SyncGroup, or the result of cls(response)

Return type

SyncGroup

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.SyncGroupListResult’][source]

Lists sync groups under a hub database.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncGroupListResult or the result of cls(response)

Return type

ItemPaged[SyncGroupListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_hub_schemas(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any) → Iterable[‘models.SyncFullSchemaPropertiesListResult’][source]

Gets a collection of hub database schemas.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncFullSchemaPropertiesListResult or the result of cls(response)

Return type

ItemPaged[SyncFullSchemaPropertiesListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_logs(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, start_time: str, end_time: str, type: Union[str, ‘models.Enum65’], continuation_token_parameter: Optional[str] = None, **kwargs: Any) → Iterable[‘models.SyncGroupLogListResult’][source]

Gets a collection of sync group logs.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

  • start_time (str) – Get logs generated after this time.

  • end_time (str) – Get logs generated before this time.

  • type (str or Enum65) – The types of logs to retrieve.

  • continuation_token_parameter (str) – The continuation token for this operation.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncGroupLogListResult or the result of cls(response)

Return type

ItemPaged[SyncGroupLogListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_sync_database_ids(location_name: str, **kwargs: Any) → Iterable[‘models.SyncDatabaseIdListResult’][source]

Gets a collection of sync database ids.

Parameters

location_name (str) – The name of the region where the resource is located.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncDatabaseIdListResult or the result of cls(response)

Return type

ItemPaged[SyncDatabaseIdListResult]

Raises

~azure.core.exceptions.HttpResponseError

trigger_sync(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any)None[source]

Triggers a sync group synchronization.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

None

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.SyncMembersOperations(client, config, serializer, deserializer)[source]

Bases: object

SyncMembersOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, parameters: ‘models.SyncMember’, **kwargs: Any) → LROPoller[‘models.SyncMember’][source]

Creates or updates a sync member.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

  • parameters (SyncMember) – The requested sync member resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either SyncMember or the result of cls(response)

Return type

LROPoller[SyncMember]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a sync member.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_refresh_member_schema(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, **kwargs: Any) → LROPoller[None][source]

Refreshes a sync member database schema.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, parameters: ‘models.SyncMember’, **kwargs: Any) → LROPoller[‘models.SyncMember’][source]

Updates an existing sync member.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

  • parameters (SyncMember) – The requested sync member resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either SyncMember or the result of cls(response)

Return type

LROPoller[SyncMember]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, **kwargs: Any) → ’models.SyncMember’[source]

Gets a sync member.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SyncMember, or the result of cls(response)

Return type

SyncMember

Raises

~azure.core.exceptions.HttpResponseError

list_by_sync_group(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, **kwargs: Any) → Iterable[‘models.SyncMemberListResult’][source]

Lists sync members in the given sync group.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncMemberListResult or the result of cls(response)

Return type

ItemPaged[SyncMemberListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_member_schemas(resource_group_name: str, server_name: str, database_name: str, sync_group_name: str, sync_member_name: str, **kwargs: Any) → Iterable[‘models.SyncFullSchemaPropertiesListResult’][source]

Gets a sync member database schema.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database on which the sync group is hosted.

  • sync_group_name (str) – The name of the sync group on which the sync member is hosted.

  • sync_member_name (str) – The name of the sync member.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either SyncFullSchemaPropertiesListResult or the result of cls(response)

Return type

ItemPaged[SyncFullSchemaPropertiesListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedInstancesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedInstancesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, managed_instance_name: str, parameters: ‘models.ManagedInstance’, **kwargs: Any) → LROPoller[‘models.ManagedInstance’][source]

Creates or updates a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • parameters (ManagedInstance) – The requested managed instance resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstance or the result of cls(response)

Return type

LROPoller[ManagedInstance]

Raises

HttpResponseError

begin_delete(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_failover(resource_group_name: str, managed_instance_name: str, replica_type: Optional[Union[str, ‘models.ReplicaType’]] = None, **kwargs: Any) → LROPoller[None][source]

Failovers a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • replica_type (str or ReplicaType) – The type of replica to be failed over.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, managed_instance_name: str, parameters: ‘models.ManagedInstanceUpdate’, **kwargs: Any) → LROPoller[‘models.ManagedInstance’][source]

Updates a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

  • parameters (ManagedInstanceUpdate) – The requested managed instance resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedInstance or the result of cls(response)

Return type

LROPoller[ManagedInstance]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → ’models.ManagedInstance’[source]

Gets a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedInstance, or the result of cls(response)

Return type

ManagedInstance

Raises

~azure.core.exceptions.HttpResponseError

list(**kwargs: Any) → Iterable[‘models.ManagedInstanceListResult’][source]

Gets a list of all managed instances in the subscription.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance_pool(resource_group_name: str, instance_pool_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceListResult’][source]

Gets a list of all managed instances in an instance pool.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • instance_pool_name (str) – The instance pool name.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_by_resource_group(resource_group_name: str, **kwargs: Any) → Iterable[‘models.ManagedInstanceListResult’][source]

Gets a list of managed instances in a resource group.

Parameters

resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedInstanceListResult or the result of cls(response)

Return type

ItemPaged[ManagedInstanceListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.BackupShortTermRetentionPoliciesOperations(client, config, serializer, deserializer)[source]

Bases: object

BackupShortTermRetentionPoliciesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, database_name: str, policy_name: Union[str, ‘models.ShortTermRetentionPolicyName’], parameters: ‘models.BackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.BackupShortTermRetentionPolicy’][source]

Updates a database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • policy_name (str or ShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (BackupShortTermRetentionPolicy) – The short term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either BackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[BackupShortTermRetentionPolicy]

Raises

HttpResponseError

begin_update(resource_group_name: str, server_name: str, database_name: str, policy_name: Union[str, ‘models.ShortTermRetentionPolicyName’], parameters: ‘models.BackupShortTermRetentionPolicy’, **kwargs: Any) → LROPoller[‘models.BackupShortTermRetentionPolicy’][source]

Updates a database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • policy_name (str or ShortTermRetentionPolicyName) – The policy name. Should always be “default”.

  • parameters (BackupShortTermRetentionPolicy) – The short term retention policy info.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either BackupShortTermRetentionPolicy or the result of cls(response)

Return type

LROPoller[BackupShortTermRetentionPolicy]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, database_name: str, policy_name: Union[str, ‘models.ShortTermRetentionPolicyName’], **kwargs: Any) → ’models.BackupShortTermRetentionPolicy’[source]

Gets a database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

  • policy_name (str or ShortTermRetentionPolicyName) – The policy name. Should always be “default”.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

BackupShortTermRetentionPolicy, or the result of cls(response)

Return type

BackupShortTermRetentionPolicy

Raises

~azure.core.exceptions.HttpResponseError

list_by_database(resource_group_name: str, server_name: str, database_name: str, **kwargs: Any) → Iterable[‘models.BackupShortTermRetentionPolicyListResult’][source]

Gets a database’s short term retention policy.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either BackupShortTermRetentionPolicyListResult or the result of cls(response)

Return type

ItemPaged[BackupShortTermRetentionPolicyListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabaseRestoreDetailsOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabaseRestoreDetailsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

get(resource_group_name: str, managed_instance_name: str, database_name: str, restore_details_name: Union[str, ‘models.RestoreDetailsName’], **kwargs: Any) → ’models.ManagedDatabaseRestoreDetailsResult’[source]

Gets managed database restore details.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • restore_details_name (str or RestoreDetailsName) – The name of the restore details to retrieve.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedDatabaseRestoreDetailsResult, or the result of cls(response)

Return type

ManagedDatabaseRestoreDetailsResult

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ManagedDatabasesOperations(client, config, serializer, deserializer)[source]

Bases: object

ManagedDatabasesOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_complete_restore(resource_group_name: str, managed_instance_name: str, database_name: str, parameters: ‘models.CompleteDatabaseRestoreDefinition’, **kwargs: Any) → LROPoller[None][source]

Completes the restore operation on a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • parameters (CompleteDatabaseRestoreDefinition) – The definition for completing the restore of this managed database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_create_or_update(resource_group_name: str, managed_instance_name: str, database_name: str, parameters: ‘models.ManagedDatabase’, **kwargs: Any) → LROPoller[‘models.ManagedDatabase’][source]

Creates a new database or updates an existing database.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • parameters (ManagedDatabase) – The requested database resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedDatabase or the result of cls(response)

Return type

LROPoller[ManagedDatabase]

Raises

HttpResponseError

begin_delete(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → LROPoller[None][source]

Deletes a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

begin_update(resource_group_name: str, managed_instance_name: str, database_name: str, parameters: ‘models.ManagedDatabaseUpdate’, **kwargs: Any) → LROPoller[‘models.ManagedDatabase’][source]

Updates an existing database.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

  • parameters (ManagedDatabaseUpdate) – The requested database resource state.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ManagedDatabase or the result of cls(response)

Return type

LROPoller[ManagedDatabase]

Raises

HttpResponseError

get(resource_group_name: str, managed_instance_name: str, database_name: str, **kwargs: Any) → ’models.ManagedDatabase’[source]

Gets a managed database.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

  • database_name (str) – The name of the database.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ManagedDatabase, or the result of cls(response)

Return type

ManagedDatabase

Raises

~azure.core.exceptions.HttpResponseError

list_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedDatabaseListResult’][source]

Gets a list of managed databases.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[ManagedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

list_inaccessible_by_instance(resource_group_name: str, managed_instance_name: str, **kwargs: Any) → Iterable[‘models.ManagedDatabaseListResult’][source]

Gets a list of inaccessible managed databases in a managed instance.

Parameters
  • resource_group_name (str) – The name of the resource group. The name is case insensitive.

  • managed_instance_name (str) – The name of the managed instance.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ManagedDatabaseListResult or the result of cls(response)

Return type

ItemPaged[ManagedDatabaseListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>
class azure.mgmt.sql.operations.ServerAzureADOnlyAuthenticationsOperations(client, config, serializer, deserializer)[source]

Bases: object

ServerAzureADOnlyAuthenticationsOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Variables

models – Alias to model classes used in this operation group.

Parameters
  • client – Client for service requests.

  • config – Configuration of service client.

  • serializer – An object model serializer.

  • deserializer – An object model deserializer.

begin_create_or_update(resource_group_name: str, server_name: str, authentication_name: Union[str, ‘models.AuthenticationName’], parameters: ‘models.ServerAzureADOnlyAuthentication’, **kwargs: Any) → LROPoller[‘models.ServerAzureADOnlyAuthentication’][source]

Sets Server Active Directory only authentication property or updates an existing server Active Directory only authentication property.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • authentication_name (str or AuthenticationName) – The name of server azure active directory only authentication.

  • parameters (ServerAzureADOnlyAuthentication) – The required parameters for creating or updating an Active Directory only authentication property.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either ServerAzureADOnlyAuthentication or the result of cls(response)

Return type

LROPoller[ServerAzureADOnlyAuthentication]

Raises

HttpResponseError

begin_delete(resource_group_name: str, server_name: str, authentication_name: Union[str, ‘models.AuthenticationName’], **kwargs: Any) → LROPoller[None][source]

Deletes an existing server Active Directory only authentication property.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • authentication_name (str or AuthenticationName) – The name of server azure active directory only authentication.

Keyword Arguments
  • cls (callable) – A custom type or function that will be passed the direct response

  • continuation_token (str) – A continuation token to restart a poller from a saved state.

  • polling (bool or PollingMethod) – True for ARMPolling, False for no polling, or a polling object for personal polling strategy

  • polling_interval (int) – Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

get(resource_group_name: str, server_name: str, authentication_name: Union[str, ‘models.AuthenticationName’], **kwargs: Any) → ’models.ServerAzureADOnlyAuthentication’[source]

Gets a specific Azure Active Directory only authentication property.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

  • authentication_name (str or AuthenticationName) – The name of server azure active directory only authentication.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

ServerAzureADOnlyAuthentication, or the result of cls(response)

Return type

ServerAzureADOnlyAuthentication

Raises

~azure.core.exceptions.HttpResponseError

list_by_server(resource_group_name: str, server_name: str, **kwargs: Any) → Iterable[‘models.AzureADOnlyAuthListResult’][source]

Gets a list of server Azure Active Directory only authentications.

Parameters
  • resource_group_name (str) – The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

  • server_name (str) – The name of the server.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

An iterator like instance of either AzureADOnlyAuthListResult or the result of cls(response)

Return type

ItemPaged[AzureADOnlyAuthListResult]

Raises

~azure.core.exceptions.HttpResponseError

models = <module 'azure.mgmt.sql.models' from '/home/vsts/work/1/s/sdk/sql/azure-mgmt-sql/.tox/sphinx/lib/python3.6/site-packages/azure/mgmt/sql/models/__init__.py'>