다음을 통해 공유


SqlServerResource.ImportDatabaseAsync Method

Definition

Imports a bacpac into a new database.

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/import
  • Operation Id: Servers_ImportDatabase
  • Default Api Version: 2023-05-01-preview
  • Resource: SqlServerResource
public virtual System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Sql.Models.ImportExportOperationResult>> ImportDatabaseAsync (Azure.WaitUntil waitUntil, Azure.ResourceManager.Sql.Models.DatabaseImportDefinition databaseImportDefinition, System.Threading.CancellationToken cancellationToken = default);
abstract member ImportDatabaseAsync : Azure.WaitUntil * Azure.ResourceManager.Sql.Models.DatabaseImportDefinition * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Sql.Models.ImportExportOperationResult>>
override this.ImportDatabaseAsync : Azure.WaitUntil * Azure.ResourceManager.Sql.Models.DatabaseImportDefinition * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Sql.Models.ImportExportOperationResult>>
Public Overridable Function ImportDatabaseAsync (waitUntil As WaitUntil, databaseImportDefinition As DatabaseImportDefinition, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ArmOperation(Of ImportExportOperationResult))

Parameters

waitUntil
WaitUntil

Completed if the method should wait to return until the long-running operation has completed on the service; Started if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples.

databaseImportDefinition
DatabaseImportDefinition

The database import request parameters.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

databaseImportDefinition is null.

Applies to