rs_get_lastcommit

Description

Returns rows from the rs_lastcommit system table.

Examples

Example 1

Creates an rs_get_lastcommit function string that executes a stored procedure named rs_get_lastcommit. The text of the stored procedure is:

create procedure rs_get_lastcommit
 as
 select origin, origin_qid, secondary_qid
   from rs_lastcommit
create function string rs_get_lastcommit
 for sqlserver_derived_class
 output language
 'execute rs_get_lastcommit'

Usage

Table 4-4: Columns returned by rs_get_lastcommit

Column name

Datatype

Description

origin

int

The ID number for the primary database the row represents

origin_qid

binary(36)

Identifies the last committed transaction in the stable queue for the origin database

secondary_qid

binary(36)

If a subscription materialization queue exists for the origin database, this column contains the last transaction in that queue that has been committed in the replicate database

See also

create function string, rs_commit