Use searchable columns in create replication definition to specify which columns to use in the where clause of create subscription or define subscription (or create article for publications) to restrict the rows copied to a subscribing site. If you do not include a searchable columns clause in a replication definition, you cannot use a where clause in a subscription or article that references that replication definition.
Enclose the names of the searchable columns in parentheses. For multiple searchable columns, separate each column from the next with a comma.
In the following example, three columns, pub_id, pub_name, and state, are specified as searchable columns. You can include any of these columns in a subscription’s where clause.
create replication definition publishers with primary at TOKYO_DS.pubs2 (pub_id char(4), pub_name varchar(40), city varchar(20), state char(2)) primary key (pub_id) searchable columns (pub_id, pub_name, state)
See “Using the where clause” for additional information on using where in subscriptions.
Searchable columns have these restrictions:
You cannot specify text, unitext, image, or Java rawobject or rawobject in row columns as searchable columns.
Columns included in the searchable columns clause cannot have null values.
To perform bitmap comparison using the where clause in the subscription, you must include any columns that use the rs_address datatype in the replication definition’s searchable columns clause. See “Using the rs_address datatype” for more information.
The more searchable columns in the searchable columns list of a replication definition, the slower Replication Server processes subscriptions; that is, the fewer searchable columns, the more efficiently Replication Server evaluates rows against subscriptions for the table.