Advantage SQL Engine
Set the property of an existing article in the data dictionary.
sp_ModifyArticleProperty(
PublicationName,CHARACTER,200,
ObjectName,CHARACTER,200,
Property,CHARACTER,200,
Value,Memo )
PublicationName (I) |
The name of the publication in the database. |
ObjectName (I) |
The name of an article in the specified publication. |
Property (I) |
Name of the property to set. See Remarks for allowed values. |
Value (I) |
Value to be stored in the data dictionary in string format. |
AE_INVALID_PROPERTY_ID |
Either the value supplied in Property is not a valid article property, or the specified property cannot be modified. |
AE_INVALID_OBJECT_NAME |
The publication specified by PublicationName cannot be located in the data dictionary, or the article specified by ObjectName does not exist in the publication. |
sp_ModifyArticleProperty sets one property for the specified article in the database. The new property overwrites the existing property in the data dictionary. The following are the valid values for Property.
Property |
Description |
FILTER |
Changes the replication filter for the article. |
IDENT_COLUMNS |
Changes the identification columns to the given semicolon or comma delimited list of columns. |
INCLUDE_COLUMNS |
Sets the vertical filter for the article to the given semicolon or comma-delimited list of columns. Only columns specified in the list will be replicated. If the property is NULL or is an empty string, the existing vertical filter is removed. Note that INCLUDE_COLUMNS and EXCLUDE_COLUMNS are mutually exclusive. Setting one property will clear the other. |
EXCLUDE_COLUMNS |
Sets the vertical filter for the article to be all columns not in the given semicolon or comma-delimited list of columns. All columns not specified in the list will be replicated. If any columns are added to the table after setting this vertical filter, the new columns will be replicated because they will not be in the exclusion list. If the property is NULL or is an empty string, the existing filter is removed. Note that INCLUDE_COLUMNS and EXCLUDE_COLUMNS are mutually exclusive. Setting one property will clear the other. |
UPDATE_MERGE |
Sets the flag that specifies whether or not this article uses SQL MERGE statements when performing UPDATEs at the target. |
INSERT_MERGE |
Sets the flag that specifies whether or not this article uses SQL MERGE statements when performing INSERTs at the target. |
// set the replication filter to a specific department
EXECUTE PROCEDURE sp_ModifyArticleProperty( 'mypub', 'table1',
'filter', 'Department = 5' );
// Set a vertical filter to replicate only four columns in the table
EXECUTE PROCEDURE sp_ModifyArticleProperty( 'mypub', 'table1',
'include_columns', 'empid;lastname;firstname;department' );
See Also