MergeArticle.ArticleResolver MergeArticle.ArticleResolver MergeArticle.ArticleResolver Property

정의

아티클을 동기화할 때 사용되는 비즈니스 논리 처리기 또는 사용자 지정 충돌 해결 프로그램의 이름을 가져오거나 설정합니다. Gets or sets the friendly name of the custom conflict resolver or business logic handler used when synchronizing the article.

public:
 property System::String ^ ArticleResolver { System::String ^ get(); void set(System::String ^ value); };
public string ArticleResolver { get; set; }
Public Property ArticleResolver As String
속성 값

A String 값입니다. A String value.

예제

// Define the Publisher, publication, and article names.
string publisherName = publisherInstance;
string publicationName = "AdvWorksSalesOrdersMerge";
string publicationDbName = "AdventureWorks2012";
string articleName = "SalesOrderHeader";

// Set the friendly name of the business logic handler.
string customLogic = "OrderEntryLogic";

MergeArticle article = new MergeArticle();

// Create a connection to the Publisher.
ServerConnection conn = new ServerConnection(publisherName);

try
{
	// Connect to the Publisher.
	conn.Connect();

	// Set the required properties for the article.
	article.ConnectionContext = conn;
	article.Name = articleName;
	article.DatabaseName = publicationDbName;
	article.PublicationName = publicationName;

	// Load the article properties.
	if (article.LoadProperties())
	{
		article.ArticleResolver = customLogic;
	}
	else
	{
		// Throw an exception of the article does not exist.
		throw new ApplicationException(String.Format(
		"{0} is not published in {1}", articleName, publicationName));
	}
	
}
catch (Exception ex)
{
	// Do error handling here and rollback the transaction.
	throw new ApplicationException(String.Format(
		"The business logic handler {0} could not be associated with " +
		" the {1} article.",customLogic,articleName), ex);
}
finally
{
	conn.Disconnect();
}
' Define the Publisher, publication, and article names.
Dim publisherName As String = publisherInstance
Dim publicationName As String = "AdvWorksSalesOrdersMerge"
Dim publicationDbName As String = "AdventureWorks2012"
Dim articleName As String = "SalesOrderHeader"

' Set the friendly name of the business logic handler.
Dim customLogic As String = "OrderEntryLogic"

Dim article As MergeArticle = New MergeArticle()

' Create a connection to the Publisher.
Dim conn As ServerConnection = New ServerConnection(publisherName)

Try
    ' Connect to the Publisher.
    conn.Connect()

    ' Set the required properties for the article.
    article.ConnectionContext = conn
    article.Name = articleName
    article.DatabaseName = publicationDbName
    article.PublicationName = publicationName

    ' Load the article properties.
    If article.LoadProperties() Then
        article.ArticleResolver = customLogic
    Else
        ' Throw an exception of the article does not exist.
        Throw New ApplicationException(String.Format( _
         "{0} is not published in {1}", articleName, publicationName))
    End If

Catch ex As Exception
    ' Do error handling here and rollback the transaction.
    Throw New ApplicationException(String.Format( _
     "The business logic handler {0} could not be associated with " + _
     " the {1} article.", customLogic, articleName), ex)
Finally
    conn.Disconnect()
End Try

설명

ArticleResolver 의 멤버 속성을 검색할 수는 sysadmin 게시자 및 구독자 (재게시 구독자)에서 고정된 서버 역할입니다.The ArticleResolver property can be retrieved by members of the sysadmin fixed server role at the Publisher and at the Subscriber (for republishing Subscribers). 멤버에 의해 검색할 수도 있습니다는 db_owner 고정된 데이터베이스 역할의 멤버에 의해 게시 데이터베이스에는 replmonitor 고정된 데이터베이스 역할 구성원 인 사용자와 배포자에서의 게시 액세스 목록 (PAL)입니다.It can also be retrieved by members of the db_owner fixed database role on the publication database, by members of the replmonitor fixed database role at the Distributor, and by users who are members of the publication access list (PAL).

ArticleResolver 속성의 멤버는 sysadmin 게시자에서 고정된 서버 역할입니다.The ArticleResolver property can be set by members of the sysadmin fixed server role at the Publisher. 멤버에 의해 설정할 수도 있습니다는 db_owner 게시 데이터베이스의 고정된 데이터베이스 역할입니다.It can also be set by members of the db_owner fixed database role on the publication database.

검색 ArticleResolver 를 실행 하는 것과 같습니다 sp_helpmergearticle (Transact SQL)합니다.Retrieving ArticleResolver is equivalent to executing sp_helpmergearticle (Transact-SQL).

설정 ArticleResolver 를 실행 하는 것과 같습니다 sp_addmergearticle (Transact SQL) 또는 sp_changemergearticle (Transact SQL)합니다.Setting ArticleResolver is equivalent to executing sp_addmergearticle (Transact-SQL) or sp_changemergearticle (Transact-SQL).

적용 대상