共用方式為


CreationScriptOptions 列舉型別

Enumerates schema option values for published articles.

此列舉型別具有允許其成員值之位元組合的 FlagsAttribute 屬性。

命名空間:  Microsoft.SqlServer.Replication
組件:  Microsoft.SqlServer.Rmo (在 Microsoft.SqlServer.Rmo.dll 中)

語法

'宣告
<FlagsAttribute> _
Public Enumeration CreationScriptOptions
'用途
Dim instance As CreationScriptOptions
[FlagsAttribute]
public enum CreationScriptOptions
[FlagsAttribute]
public enum class CreationScriptOptions
[<FlagsAttribute>]
type CreationScriptOptions
public enum CreationScriptOptions

成員

成員名稱 描述
DisableScripting Object creation scripts are not generated by the Snapshot Agent. You must specify a user-supplied script file to define the object at the Subscriber for CreationScript.
PrimaryObject Generates a creation script (CREATE TABLE, CREATE PROCEDURE, and so on) for the published object.
CustomProcedures Includes the generation of custom stored procedures. This option is only valid for the TransArticle object. You must also specify InsertCommand, UpdateCommand, and DeleteCommand.
Identity Includes the creation of identity columns. This option is supported only for TransArticle objects and only for Microsoft SQL Server 2005 and later releases. For more information, see 複寫識別欄位.
KeepTimestamp Replicates timestamp columns. Without this option, timestamp columns are created on the Subscriber as binary(16) columns. This option is supported only for TransArticle objects.
ClusteredIndexes Includes the creation of a corresponding clustered index.
UserDefinedTypesToBaseTypes Converts user-defined data types columns at the Publisher to base SQL Server data type columns at the Subscriber. This option is not supported for non-SQL Server Publishers.
NonClusteredIndexes Includes the creation of nonclustered indexes.
DriPrimaryKey Includes the creation of primary key constraints.
UserTriggers Includes the creation of user-defined triggers.
DriForeignKeys Includes the creation of foreign key constraints to all referenced tables that are included in the publication.
DriChecks Includes the creation CHECK constraints.
DriDefaults Includes the creation column defaults.
Collation Includes the definition of a column-level collation.
ExtendedProperties Includes the extended properties associated with the database object being published.
DriUniqueKeys Includes the creation of unique keys.
PrimaryKeyUniqueKeyAsConstraints Generates ALTER TABLE statements when replicating constraints.
MarkReplicatedCheckConstraintsAsNotForReplication Includes the NOT FOR REPLICATION clause when creating CHECK constraints so that the constraints are not enforced during synchronization. For more information, see 使用 NOT FOR REPLICATION 控制條件約束、識別和觸發程序.
MarkReplicatedForeignKeyConstraintsAsNotForReplication Includes the NOT FOR REPLICATION clause when creating FOREIGN KEY constraints so that the constraints are not enforced during synchronization. For more information, see 使用 NOT FOR REPLICATION 控制條件約束、識別和觸發程序.
FileGroups Includes the filegroups associated with a partitioned table or index.
附註附註
The underlying filegroup layout must be created at the subscriber before the initial snapshot is applied.
TablePartitioningScheme Includes the partition scheme associated with a partitioned table.
附註附註
The underlying partition scheme must be created at the subscriber before the initial snapshot is applied.
IndexPartitioningSchemes Includes the partition scheme associated with a partitioned index.
附註附註
The underlying partition scheme must be created at the subscriber before the initial snapshot is applied.
Statistics Includes user-defined table statistics.
DefaultBindings Includes default bindings and creation of the bound defaults.
RuleBindings Includes rule bindings and creation of the bound rules.
FullTextIndex Includes full-text indexes.
NoXmlSchemaCollections XML schema collections bound to xml columns are not included.
XmlIndexes Includes XML indexes.
Schema Generates any schemas not already present on the subscriber.
XmlToNText xml columns are replicated to the Subscriber as ntext.
MaxTypesToMatchingNonMaxTypes Converts nvarchar(max), varchar(max), and varbinary(max) to ntext, text, and image data types, which are supported on earlier versions of SQL Server.
Permissions Includes permissions defined on the published object.
AttemptToDropNonArticleDependencies At the Subscriber, attempts to drop dependencies to any objects that are not part of the publication.
FileStreamAttribute Use this option to replicate the FILESTREAM attribute if it is specified on varbinary(max) columns. Do not specify this option if you are replicating tables to SQL Server 2005 Subscribers. Replicating tables that have FILESTREAM columns to SQL Server 2000 Subscribers is not supported, regardless of how this schema option is set.
NewDateTimeTypesToStrings Converts date and time data types (date, time, datetimeoffset, and datetime2) introduced in SQL Server 2008 to data types that are supported on earlier versions of SQL Server. For information about how these types are mapped, see the "Mapping New Data Types for Earlier Versions" section in 在複寫拓撲中使用多個 SQL Server 版本.
StorageCompressionSetting Replicates the compression option for data and indexes. For more information, see 建立壓縮資料表及索引.
LargeUserDefinedTypesToVarBinaryMax Converts common language runtime (CLR) user-defined types (UDTs) that are larger than 8000 bytes to varbinary(max) so that columns of type UDT can be replicated to Subscribers that are running SQL Server 2005.
HierarchyIdToVarBinaryMax Converts the hierarchyid data type to varbinary(max) so that columns of type hierarchyid can be replicated to Subscribers that are running SQL Server 2005. For more information about how to use hierarchyid columns in replicated tables, see hierarchyid (Transact-SQL).
FilteredIndexes Replicates any filtered indexes on the table. For more information about filtered indexes, see 篩選索引設計指導方針.
FileStreamDataSpace Set this option to store FILESTREAM data on its own filegroup at the Subscriber. If this option is not set, FILESTREAM data is stored on the default filegroup. Replication does not create filegroups; therefore, if you set this option, you must create the filegroup before you apply the snapshot at the Subscriber. For more information about how to create objects before you apply the snapshot, see 在套用快照集的前後執行指令碼.
SpatialTypesToVarBinaryMax Converts the geography and geometry data types to varbinary(max) so that columns of these types can be replicated to Subscribers that are running SQL Server 2005.
SpatialIndexes Replicates indexes on columns of type geography and geometry.
SparseAttribute Replicates the SPARSE attribute for columns. For more information about this attribute, see 使用疏鬆資料行.

備註

The schema options for an article control how the published object will created at the Subscriber, and affect how the snapshot script files are generated. For more information, see 發行資料和資料庫物件.

Values of the CreationScriptOptions enumeration are equivalent to values of the @schema_option parameter of sp_addarticle (Transact-SQL) and sp_addmergearticle (Transact-SQL).

The CreationScriptOptions enumeration supports the FlagsAttribute option which allows bitwise combination of enumeration values.

This namespace, class, or member is supported only in version 2.0 of the Microsoft .NET Framework.