User's Manual
Chapter 8. SQL Remote Design for Adaptive Server Enterprise
Log entries are values, not subscribers
Although in this case the values entered correspond to subscribers, it is
not a list of subscribers that is entered in the log. The server handles
only information about publications, and the Message Agent handles
all information about subscribers. The values entered in the log are for
comparison to the subscription value in each subscription. For example,
if rows of a table were divided among sales representatives by state or
province, the state or province value would be entered in the transaction
log.
A subscription-list column is a column added to a table for the sole
purpose of holding a comma-separated list of subscribers. In the present
case, there can only be a single subscriber to each row of the Contact table,
and so the subscription-list column holds only a single value.
☞ For a discussion of the case where the subscription-list column can hold
many values, see “Sharing rows among several subscriptions” on page 157.
Contact table definition In the case of the Contact table, the table definition would be changed to the
following:
CREATE TABLE Contact (
contact_key CHAR( 12 ) NOT NULL,
name CHAR( 40 ) NOT NULL,
cust_key CHAR( 12 ) NOT NULL,
subscription_list CHAR( 12 ) NULL,
FOREIGN KEY ( cust_key )
REFERENCES Customer ( cust_key ),
PRIMARY KEY ( contact_key )
)
go
The additional column is created allowing NULL, so that existing
applications can continue to work against the database without change.
The subscription_list column holds the rep_key value corresponding to the
row with primary key value cust_key in the Customer table. A set of
triggers handles maintenance of the subscription_list column.
153