Show TOC

rs_update_threadsLocate this document in the navigation structure

Updates the sequence number for the specified entry in the <rs_threads> system table.

Syntax
rs_update_threads @<rs_id>, @<rs_seq>
Parameters
rs_id

A number of <int> datatype representing the ID of the entry to be updated.

rs_seq

A number of <int> datatype representing the new sequence number for the entry.

Examples
Example 1

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

create function string rs_update_threads
  for sqlserver_derived_class
  output language
  'execute rs_update_threads
  @rs_seq = ?rs_seq!param?,
  @rs_id = ?rs_id!param?'
create procedure rs_update_threads
  @rs_id int,
  @rs_seq int
  as
  update rs_threads set seq = @rs_seq
    where id = @rs_id
Usage
  • The rs_update_threads function is executed at the start of each transaction when more than one DSI thread is defined for a connection. It is executed only when more than one DSI thread is defined for a connection.

  • The rs_update_threads function has function-string-class scope.

  • Replication Server creates an initial rs_update_threads function string for the system-provided function-string classes during installation.

  • If you use a user-created base function-string class and the parallel DSI feature, create a function string for rs_update_threads.

  • Create or customize an rs_update_threads function string at the Replication Server that is the primary site for the class.