Partilhar via


Método AvailabilityDatabase.ResumeDataMovement

Resumes the data movement on this availability database.

Namespace:  Microsoft.SqlServer.Management.Smo
Assembly:  Microsoft.SqlServer.Smo (em Microsoft.SqlServer.Smo.dll)

Sintaxe

'Declaração
Public Sub ResumeDataMovement
'Uso
Dim instance As AvailabilityDatabase

instance.ResumeDataMovement()
public void ResumeDataMovement()
public:
void ResumeDataMovement()
member ResumeDataMovement : unit -> unit
public function ResumeDataMovement()

Comentários

Data movement on this availability database may not yet have resumed after a call to ResumeDataMovement() returns control to the program. The following code snippet suggests one way to pause program execution until data movement on this availability database resumes:

Server server = new Server("PrimaryServerName");
AvailabilityGroup ag = server.AvailabilityGroups["AgName"];
AvailabilityDatabase dbToResume = ag.AvailabilityDatabases["DbName"];
dbToResume.ResumeDataMovement();
while (dbToResume.IsJoined) {
    Thread.Sleep(5000);
    dbToResume.Refresh();
}

Consulte também

Referência

AvailabilityDatabase Classe

Namespace Microsoft.SqlServer.Management.Smo