Oracle8i Replication Management API Reference
Release 2 (8.1.6)

Part Number A76958-01

Library

Product

Contents

Index

Go to previous page Go to beginning of chapter Go to next page

Replication Management API Reference, 73 of 179


COMPARE_OLD_VALUES procedure

This procedure lets you compare old column values at each master site for each non-key column of a replicated table for updates and deletes. The default is to compare old values for all columns. You can change this behavior at all master and snapshot sites by invoking DBMS_REPCAT.COMPARE_OLD_VALUES at the master definition site.

Syntax

DBMS_REPCAT.COMPARE_OLD_VALUES(
   sname           IN  VARCHAR2,
   oname           IN  VARCHAR2,
   { column_list   IN  VARCHAR2,
   | column_table  IN  DBMS_REPCAT.VARCHAR2s,}
   operation       IN  VARCHAR2 := `UPDATE',
   compare         IN  BOOLEAN := TRUE );


Note:

This procedure is overloaded. The column_list and column_table parameters are mutually exclusive. 


Parameters

Table 8-124 COMPARE_OLD_VALUES Procedure Parameters (Page 1 of 2)
Parameter  Description 
sname
 

Schema in which the table is located.  

oname
 

Name of the replicated table.  

column_list
 

A comma-separated list of the columns in the table. There must be no white space between entries. 

column_table
 

Instead of a list, you can use a PL/SQL table of type DBMS_REPCAT.VARCHAR2s to contain the column names. The first column name should be at position 1, the second at position 2, and so on. 

operation
 

Possible values are: UPDATE, DELETE, or the asterisk wildcard '*', which means update and delete. 

compare
 

If compare is TRUE, the old values of the specified columns are compared when sent. If compare is FALSE, the old values of the specified columns are not compared when sent. Unspecified columns and unspecified operations are not affected. The specified change takes effect at the master definition site as soon as min_communication is TRUE for the table. The change takes effect at a master site or at a snapshot site the next time replication support is generated at that site with min_communication TRUE. 


Note:

The operation parameter allows you to decide whether or not to transmit old values for non-key columns when rows are deleted or when non-key columns are updated. If you do not send the old value, then Oracle sends a NULL in place of the old value and assumes the old value is equal to the current value of the column at the target side when the update or delete is applied.

See Oracle8i Replication for information about reduced data propagation before changing the default behavior of Oracle.  


Exceptions

Table 8-125 COMPARE_OLD_VALUES Procedure Exceptions
Exception  Description 
nonmasterdef
 

Invocation site is not the master definition site. 

missingobject
 

Specified object does not exist as a table in the specified schema awaiting row-level replication information. 

missingcolumn
 

At least one column is not in the table.  

notquiesced
 

Replicated master group has not been quiesced. 

typefailure
 

An illegal operation is specified. 


Go to previous page Go to beginning of chapter Go to next page
Oracle
Copyright © 1996-2000, Oracle Corporation.

All Rights Reserved.

Library

Product

Contents

Index