ttRepSubscriberStateSet

This procedure changes a replicating subscriber's state with respect to the master store.

Required Privilege

This procedure requires the ADMIN privilege.

Usage in TimesTen Scaleout and TimesTen Classic

This procedure is supported in TimesTen Classic but not supported in TimesTen Scaleout.

Related Views

This procedure has no related views.

Syntax

ttRepSubscriberStateSet('replicationName', 'replicationOwner',
 'subscriberStoreName', 'subscriberHostName', newStateCode)

Parameters

ttRepSubscriberStateSet has these parameters:

Parameter Type Description

replicationName

TT_CHAR (30)

The name of the replication scheme on which to operate. May be NULL to indicate all replication schemes.

replicationOwner

TT_CHAR (30)

The owner of the replication scheme. May be NULL to indicate all replication scheme owners.

subscriberStoreName

TT_VARCHAR (200)

The name of the subscribing database whose state is to be set. May be NULL to indicate all stores on host subscriberHostName.

subscriberHostName

TT_VARCHAR (200)

The subscriber's host. May be NULL to indicate all hosts of subscribing peers.

newStateCode

TT_INTEGER

An integer code representing the specified subscriber's new state:

0/NULL - Start (default). Starts replication to the subscriber.

1 - Pause. Pauses the replication agent, preserving updates.

2 - Stop. Stops replication to the subscriber, discarding updates.

All other state codes are disallowed. (This procedure cannot set a subscriber state to "failed.") Set the Replication State of Subscribers in the Oracle TimesTen In-Memory Database Replication GuideOracle TimesTen In-Memory Database Replication Guide for more information.

Result Set

ttRepSubscriberStateSet returns no results.

Examples

For the replication scheme named REPL.REPSCHEME, the following directs the master database to set the state of the subscriber database (SUBSCRIBERDS ON SYSTEM1) to Stop (2):

CALL ttRepSubscriberStateSet('REPSCHEME', 'REPL', 
'SUBSCRIBERDS','SYSTEM1', 2);

To direct the master database to set the state of all its subscribers to Pause (1), use:

CALL ttRepSubscriberStateSet( , , , , 1 );

Leaving a parameter empty is equivalent to using NULL.