Share via


TransPublication.ValidateSubscriptions Method

Definition

Invokes inline publication validation for the specified subscription.

public:
 void ValidateSubscriptions(cli::array <System::String ^> ^ subscriberNames, cli::array <System::String ^> ^ subscriptionDBs, Microsoft::SqlServer::Replication::ValidationOption validationOption, Microsoft::SqlServer::Replication::ValidationMethod validationMethod, bool shutdownAgent);
public void ValidateSubscriptions (string[] subscriberNames, string[] subscriptionDBs, Microsoft.SqlServer.Replication.ValidationOption validationOption, Microsoft.SqlServer.Replication.ValidationMethod validationMethod, bool shutdownAgent);
member this.ValidateSubscriptions : string[] * string[] * Microsoft.SqlServer.Replication.ValidationOption * Microsoft.SqlServer.Replication.ValidationMethod * bool -> unit
Public Sub ValidateSubscriptions (subscriberNames As String(), subscriptionDBs As String(), validationOption As ValidationOption, validationMethod As ValidationMethod, shutdownAgent As Boolean)

Parameters

subscriberNames
String[]

An array of String objects that specifies the names of the Subscribers.

subscriptionDBs
String[]

An array of String objects that specifies the names of the subscription databases.

validationOption
ValidationOption

A ValidationOption object value that specifies the type of validation being performed.

validationMethod
ValidationMethod

A ValidationMethod object value that specifies options for rowcount validation.

shutdownAgent
Boolean

A Boolean value. If true, the Distribution Agent is shut down immediately after validation. If false, the Distribution Agent continues to run.

Remarks

The result of the validation operation is written to the agent history, which is viewed using Replication Monitor.

The result of the validation is written to the agent history, which is viewed using Replication Monitor. For more information, see Monitoring Replication.

The ValidateSubscriptions method can only be called by members of the sysadmin fixed server role at the Publisher or by members of the db_owner fixed database role on the publication database.

Calling ValidateSubscriptions is equivalent to executing sp_marksubscriptionvalidation and sp_article_validation.

Applies to