2. Add the table to the publication. Youdo this by executing the
sp_add_articleprocedure:
sp_add_article publication-name, table-name
go
Thesp_add_article procedure adds a table to a publication. By default,
allcolumns of the table are added to the publication. Ifyou wish to add
onlysome of the columns, you must use the sp_add_article_col
procedureto specify which columns you wish to include.
3. Add individual columns to the publication. Youdo this by executing the
sp_add_article_colprocedure for each column:
sp_add_article_col publication-name,
table-name,
column-name
go
Example Thefollowing commands add only the rep_key column of the table
SalesRepto the SalesRepData publication:
sp_add_remote_table ’SalesRep’
sp_add_article ’SalesRepData’,
’SalesRep’
sp_add_article_col ’SalesRepData’,
’SalesRep’,
’rep_key’
go
Creating articles containing some of the rows in a table
Thereare two ways of including only some of the rows from a table in an
article:
WHEREclause Youcan use a WHERE clause to include a subset of
rowsin an article. Allsubscribers to the publication containing this
articlereceive the rows that satisfy the WHERE clause.
subscriptioncolumn Youcan use a subscription column to include a
differentset of rows in different subscriptions to publications containing
thearticle.
Allowedclauses InSQL Remote for Adaptive Server Enterprise, the following limitations
applyto each of these cases:
WHEREclause limitations The only form of WHERE clause
supportedis the following:
WHERE column-name IS NOT NULL.
144