ArticleOptions ArticleOptions ArticleOptions Enum

정의

복제를 통해 게시할 수 있는 데이터베이스 개체의 유형을 열거합니다. Enumerates the type of database objects that can be published by replication.

public enum class ArticleOptions
public enum ArticleOptions
Public Enum ArticleOptions
상속
ArticleOptionsArticleOptionsArticleOptions

필드

AggregateSchemaOnly AggregateSchemaOnly AggregateSchemaOnly 96

게시된 아티클의 원본 개체는 사용자 정의 집계 함수의 스키마 정의입니다. The source object for the published article is the schema definition of a user-defined aggregate function.

FunctionSchemaOnly FunctionSchemaOnly FunctionSchemaOnly 128

게시된 아티클의 원본 개체는 사용자 정의 함수의 스키마 정의입니다. The source object for the published article is the schema definition of a user-defined function.

IndexedView IndexedView IndexedView 256

게시된 아티클의 원본 개체는 인덱싱된 뷰입니다. The source object for the published article is an indexed view.

IndexedViewLogBased IndexedViewLogBased IndexedViewLogBased 257

게시된 아티클의 원본 개체는 인덱싱된 뷰이고 로그에서 데이터 변경 내용을 읽습니다. The source object for the published article is an indexed view, and data changes are read from the log.

IndexedViewLogBasedManualBoth IndexedViewLogBasedManualBoth IndexedViewLogBasedManualBoth 263

게시된 아티클의 원본 개체는 인덱싱된 뷰입니다. The source object for the published article is an indexed view. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있습니다. Data changes are read from the transaction log. 사용자는 아티클에 대한 초기 스냅숏 데이터를 제공하는 개체 및 아티클을 행 필터링하는 저장 프로시저를 정의합니다. The user defines the object that provides the initial snapshot data for the article and the stored procedure that filters the article horizontally.

IndexedViewLogBasedManualFilterProc IndexedViewLogBasedManualFilterProc IndexedViewLogBasedManualFilterProc 259

게시된 아티클의 원본 개체는 인덱싱된 뷰입니다. The source object for the published article is an indexed view. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있으며 사용자는 아티클을 행 필터링하는 저장 프로시저를 정의합니다. Data changes are read from the transaction log, and the user defines the stored procedure that filters the article horizontally.

IndexedViewLogBasedManualSyncView IndexedViewLogBasedManualSyncView IndexedViewLogBasedManualSyncView 261

게시된 아티클의 원본 개체는 인덱싱된 뷰입니다. The source object for the published article is an indexed view. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있으며 사용자는 아티클에 대한 초기 스냅숏 데이터를 제공하는 개체를 정의합니다. Data changes are read from the transaction log, and the user defines the object that provides the initial snapshot data for the article.

IndexedViewSchemaOnly IndexedViewSchemaOnly IndexedViewSchemaOnly 320

게시된 아티클의 원본 개체는 인덱싱된 뷰의 스키마 정의입니다. The source object for the published article is the schema definition of an indexed view.

LogBased LogBased LogBased 1

게시된 아티클의 원본 개체는 테이블입니다. The source object for the published article is a table. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있습니다. Data changes are read from the transaction log.

LogBasedManualBoth LogBasedManualBoth LogBasedManualBoth 7

게시된 아티클의 원본 개체는 테이블입니다. The source object for the published article is a table. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있습니다. Data changes are read from the transaction log. 사용자는 아티클에 대한 초기 스냅숏 데이터를 제공하는 개체 및 아티클을 행 필터링하는 저장 프로시저를 정의합니다. The user defines the object that provides the initial snapshot data for the article and the stored procedure that filters the article horizontally.

LogBasedManualFilterProc LogBasedManualFilterProc LogBasedManualFilterProc 3

게시된 아티클의 원본 개체는 테이블입니다. The source object for the published article is a table. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있으며 사용자는 아티클을 행 필터링하는 저장 프로시저를 정의합니다. Data changes are read from the transaction log, and the user defines the stored procedure that filters the article horizontally.

LogBasedManualSyncView LogBasedManualSyncView LogBasedManualSyncView 5

게시된 아티클의 원본 개체는 테이블입니다. The source object for the published article is a table. 트랜잭션 로그에서 데이터 변경 내용을 읽을 수 있으며 사용자는 아티클에 대한 초기 스냅숏 데이터를 제공하는 개체를 정의합니다. Data changes are read from the transaction log, and the user defines the object that provides the initial snapshot data for the article.

ManualFilterProc ManualFilterProc ManualFilterProc 2

사용자는 아티클을 행 필터링하는 저장 프로시저를 정의합니다. The user defines the stored procedure that filters the article horizontally.

ManualSyncView ManualSyncView ManualSyncView 4

사용자는 아티클에 대한 초기 스냅숏 데이터를 제공하는 개체를 정의합니다. The user defines the object that provides the initial snapshot data for the article.

ProcExecution ProcExecution ProcExecution 8

게시된 아티클의 원본은 저장 프로시저 실행입니다. The source for the published article is the execution of a stored procedure. 저장 프로시저의 명령은 구독자에 복제됩니다. The commands in the stored procedure are replicated to the Subscriber.

ProcSchemaOnly ProcSchemaOnly ProcSchemaOnly 32

게시된 아티클의 원본 개체는 저장 프로시저의 스키마 정의입니다. The source object for the published article is the schema definition of a stored procedure.

SerializableProcExecution SerializableProcExecution SerializableProcExecution 24

게시된 아티클의 원본은 저장 프로시저 실행입니다. The source for the published article is the execution of a stored procedure. 직렬화할 수 있는 트랜잭션의 컨텍스트 내에 있는 저장 프로시저 명령만 구독자에 복제됩니다. Only the commands of the stored procedure that are within the context of a transaction that can be serialized are replicated to the Subscriber.

SynonymSchemaOnly SynonymSchemaOnly SynonymSchemaOnly 160

게시된 아티클의 원본 개체는 동의어의 스키마 정의입니다. The source object for the published article is the schema definition of a synonym.

TableBased TableBased TableBased 10

게시된 아티클의 원본 개체는 테이블입니다. The source object for the published article is a table.

ViewSchemaOnly ViewSchemaOnly ViewSchemaOnly 64

게시된 아티클의 원본 개체는 뷰의 스키마 정의입니다. The source object for the published article is the schema definition of a view.

예제

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

// Specify article names.
string articleName1 = "Employee";
string articleName2 = "SalesOrderHeader";
string articleName3 = "SalesOrderDetail";

// Specify join filter information.
string filterName12 = "SalesOrderHeader_Employee";
string filterClause12 = "Employee.EmployeeID = " +
	"SalesOrderHeader.SalesPersonID";
string filterName23 = "SalesOrderDetail_SalesOrderHeader";
string filterClause23 = "SalesOrderHeader.SalesOrderID = " +
	"SalesOrderDetail.SalesOrderID";

string salesSchema = "Sales";
string hrSchema = "HumanResources";

MergeArticle article1 = new MergeArticle();
MergeArticle article2 = new MergeArticle();
MergeArticle article3 = new MergeArticle();
MergeJoinFilter filter12 = new MergeJoinFilter();
MergeJoinFilter filter23 = new MergeJoinFilter();

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

// Create three merge articles that are horizontally partitioned
// using a parameterized row filter on Employee.EmployeeID, which is 
// extended to the two other articles using join filters. 
try
{
	// Connect to the Publisher.
	conn.Connect();

	// Create each article. 
	// For clarity, each article is defined separately. 
	// In practice, iterative structures and arrays should 
	// be used to efficiently create multiple articles.

	// Set the required properties for the Employee article.
	article1.ConnectionContext = conn;
	article1.Name = articleName1;
	article1.DatabaseName = publicationDbName;
	article1.SourceObjectName = articleName1;
	article1.SourceObjectOwner = hrSchema;
	article1.PublicationName = publicationName;
	article1.Type = ArticleOptions.TableBased;

	// Define the parameterized filter clause based on Hostname.
	article1.FilterClause = "Employee.LoginID = HOST_NAME()";

	// Set the required properties for the SalesOrderHeader article.
	article2.ConnectionContext = conn;
	article2.Name = articleName2;
	article2.DatabaseName = publicationDbName;
	article2.SourceObjectName = articleName2;
	article2.SourceObjectOwner = salesSchema;
	article2.PublicationName = publicationName;
	article2.Type = ArticleOptions.TableBased;

	// Set the required properties for the SalesOrderDetail article.
	article3.ConnectionContext = conn;
	article3.Name = articleName3;
	article3.DatabaseName = publicationDbName;
	article3.SourceObjectName = articleName3;
	article3.SourceObjectOwner = salesSchema;
	article3.PublicationName = publicationName;
	article3.Type = ArticleOptions.TableBased;

	if (!article1.IsExistingObject) article1.Create();
	if (!article2.IsExistingObject) article2.Create();
	if (!article3.IsExistingObject) article3.Create();

	// Select published columns for SalesOrderHeader.
	// Create an array of column names to vertically filter out.
	// In this example, only one column is removed.
	String[] columns = new String[1];

	columns[0] = "CreditCardApprovalCode";

	// Remove the column.
	article2.RemoveReplicatedColumns(columns);

	// Define a merge filter clauses that filter 
	// SalesOrderHeader based on Employee and 
	// SalesOrderDetail based on SalesOrderHeader. 

	// Parent article.
	filter12.JoinArticleName = articleName1;
	// Child article.
	filter12.ArticleName = articleName2;
	filter12.FilterName = filterName12;
	filter12.JoinUniqueKey = true;
	filter12.FilterTypes = FilterTypes.JoinFilter;
	filter12.JoinFilterClause = filterClause12;

	// Add the join filter to the child article.
	article2.AddMergeJoinFilter(filter12);

	// Parent article.
	filter23.JoinArticleName = articleName2;
	// Child article.
	filter23.ArticleName = articleName3;
	filter23.FilterName = filterName23;
	filter23.JoinUniqueKey = true;
	filter23.FilterTypes = FilterTypes.JoinFilter;
	filter23.JoinFilterClause = filterClause23;

	// Add the join filter to the child article.
	article3.AddMergeJoinFilter(filter23);
}
catch (Exception ex)
{
	// Do error handling here and rollback the transaction.
	throw new ApplicationException(
		"The filtered articles could not be created", ex);
}
finally
{
	conn.Disconnect();
}
' Define the Publisher and publication names.
Dim publisherName As String = publisherInstance
Dim publicationName As String = "AdvWorksSalesOrdersMerge"
Dim publicationDbName As String = "AdventureWorks2012"

' Specify article names.
Dim articleName1 As String = "Employee"
Dim articleName2 As String = "SalesOrderHeader"
Dim articleName3 As String = "SalesOrderDetail"

' Specify join filter information.
Dim filterName12 As String = "SalesOrderHeader_Employee"
Dim filterClause12 As String = "Employee.EmployeeID = " + _
    "SalesOrderHeader.SalesPersonID"
Dim filterName23 As String = "SalesOrderDetail_SalesOrderHeader"
Dim filterClause23 As String = "SalesOrderHeader.SalesOrderID = " + _
    "SalesOrderDetail.SalesOrderID"

Dim salesSchema As String = "Sales"
Dim hrSchema As String = "HumanResources"

Dim article1 As MergeArticle = New MergeArticle()
Dim article2 As MergeArticle = New MergeArticle()
Dim article3 As MergeArticle = New MergeArticle()
Dim filter12 As MergeJoinFilter = New MergeJoinFilter()
Dim filter23 As MergeJoinFilter = New MergeJoinFilter()

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

' Create three merge articles that are horizontally partitioned
' using a parameterized row filter on Employee.EmployeeID, which is 
' extended to the two other articles using join filters. 
Try
    ' Connect to the Publisher.
    conn.Connect()

    ' Create each article. 
    ' For clarity, each article is defined separately. 
    ' In practice, iterative structures and arrays should 
    ' be used to efficiently create multiple articles.

    ' Set the required properties for the Employee article.
    article1.ConnectionContext = conn
    article1.Name = articleName1
    article1.DatabaseName = publicationDbName
    article1.SourceObjectName = articleName1
    article1.SourceObjectOwner = hrSchema
    article1.PublicationName = publicationName
    article1.Type = ArticleOptions.TableBased

    ' Define the parameterized filter clause based on Hostname.
    article1.FilterClause = "Employee.LoginID = HOST_NAME()"

    ' Set the required properties for the SalesOrderHeader article.
    article2.ConnectionContext = conn
    article2.Name = articleName2
    article2.DatabaseName = publicationDbName
    article2.SourceObjectName = articleName2
    article2.SourceObjectOwner = salesSchema
    article2.PublicationName = publicationName
    article2.Type = ArticleOptions.TableBased

    ' Set the required properties for the SalesOrderDetail article.
    article3.ConnectionContext = conn
    article3.Name = articleName3
    article3.DatabaseName = publicationDbName
    article3.SourceObjectName = articleName3
    article3.SourceObjectOwner = salesSchema
    article3.PublicationName = publicationName
    article3.Type = ArticleOptions.TableBased

    ' Create the articles, if they do not already exist.
    If article1.IsExistingObject = False Then
        article1.Create()
    End If
    If article2.IsExistingObject = False Then
        article2.Create()
    End If
    If article3.IsExistingObject = False Then
        article3.Create()
    End If

    ' Select published columns for SalesOrderHeader.
    ' Create an array of column names to vertically filter out.
    ' In this example, only one column is removed.
    Dim columns() As String = New String(0) {}

    columns(0) = "CreditCardApprovalCode"

    ' Remove the column.
    article2.RemoveReplicatedColumns(columns)

    ' Define a merge filter clauses that filter 
    ' SalesOrderHeader based on Employee and 
    ' SalesOrderDetail based on SalesOrderHeader. 

    ' Parent article.
    filter12.JoinArticleName = articleName1
    ' Child article.
    filter12.ArticleName = articleName2
    filter12.FilterName = filterName12
    filter12.JoinUniqueKey = True
    filter12.FilterTypes = FilterTypes.JoinFilter
    filter12.JoinFilterClause = filterClause12

    ' Add the join filter to the child article.
    article2.AddMergeJoinFilter(filter12)

    ' Parent article.
    filter23.JoinArticleName = articleName2
    ' Child article.
    filter23.ArticleName = articleName3
    filter23.FilterName = filterName23
    filter23.JoinUniqueKey = True
    filter23.FilterTypes = FilterTypes.JoinFilter
    filter23.JoinFilterClause = filterClause23

    ' Add the join filter to the child article.
    article3.AddMergeJoinFilter(filter23)

Catch ex As Exception
    ' Do error handling here and rollback the transaction.
    Throw New ApplicationException( _
        "The filtered articles could not be created", ex)
Finally
    conn.Disconnect()
End Try

설명

필드 값 ArticleOptions 의 지원 되는 값에 해당는 ** @type ** 매개 변수에서 sp_addarticle (TRANSACT-SQL)sp_addmergearticle 드 ( Transact-SQL)합니다.The field values of ArticleOptions are equivalent to the supported values of the @type parameter in sp_addarticle (Transact-SQL) and sp_addmergearticle (Transact-SQL).

ArticleOptions 열거형 지원은 FlagsAttribute 열거형 값의 비트 조합을 허용 하는 옵션입니다.The ArticleOptions enumeration supports the FlagsAttribute option, which allows a bitwise combination of enumeration values. 그러나 각 지원 되는 문서 유형에 별도 값을는 되므로 비트 연산 필요 하지 않습니다.However, each supported article type has a separate value, so bitwise operations are not required.

일부 ArticleOptions 모든 유형의 복제에 대해 지원 됩니다.Not all ArticleOptions are supported for all types of replication.

이 네임 스페이스, 클래스 또는 멤버에만 지원 되는 Microsoft .NET Framework 버전 2.0.This namespace, class, or member is supported only in the Microsoft .NET Framework version 2.0.

적용 대상