Skip Headers

Oracle® Database Advanced Replication Management API Reference
10g Release 1 (10.1)

Part Number B10733-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Feedback

Go to previous page
Previous
Go to current chapter
Up
Go to next page
Next
View PDF

VALIDATE Function

This function validates the correctness of key conditions of a multimaster replication environment.

Syntax

DBMS_REPCAT.VALIDATE (
   gname               IN  VARCHAR2, 
   check_genflags      IN  BOOLEAN := false,
   check_valid_objs    IN  BOOLEAN := false,
   check_links_sched   IN  BOOLEAN := false,
   check_links         IN  BOOLEAN := false,
   error_table         OUT DBMS_REPCAT.VALIDATE_ERR_TABLE)
  RETURN BINARY_INTEGER;

DBMS_REPCAT.VALIDATE (
   gname               IN  VARCHAR2, 
   check_genflags      IN  BOOLEAN := false,
   check_valid_objs    IN  BOOLEAN := false,
   check_links_sched   IN  BOOLEAN := false,
   check_links         IN  BOOLEAN := false,
   error_msg_table     OUT DBMS_UTILITY.UNCL_ARRAY,
   error_num_table     OUT DBMS_UTILITY.NUMBER_ARRAY )
  RETURN BINARY_INTEGER;

Note:

This function is overloaded. The return value of VALIDATE is the number of errors found. The function's OUT parameter returns any errors that are found. In the first interface function shown under "Syntax", the error_table consists of an array of records. Each record has a VARCHAR2 and a NUMBER in it. The string field contains the error message, and the number field contains the Oracle error number.

The second interface function shown under "Syntax" is similar except that there are two OUT arrays: a VARCHAR2 array with the error messages and a NUMBER array with the error numbers.


Parameters

Table 18-140 VALIDATE Function Parameters 
Parameter Description
gname

Name of the master group to validate.

check_genflags

Check whether all the objects in the group are generated. This must be done at the master definition site only.

check_valid_objs

Check that the underlying objects for objects in the group valid. This must be done at the master definition site only. The master definition site goes to all other sites and checks that the underlying objects are valid. The validity of the objects is checked within the schema of the connected user.

check_links_sched

Check whether the links are scheduled for execution. This should be invoked at each master site.

check_links

Check whether the connected user (repadmin), as well as the propagator, have correct links for replication to work properly. Checks that the links exist in the database and are accessible. This should be invoked at each master site.

error_table

Returns the messages and numbers of all errors that are found.

error_msg_table

Returns the messages of all errors that are found.

error_num_table

Returns the numbers of all errors that are found.

Exceptions

Table 18-141 VALIDATE Function Exceptions
Exception Description
missingdblink

Database link does not exist in the schema of the replication propagator or has not been scheduled. Ensure that the database link exists in the database, is accessible, and is scheduled for execution.

dblinkmismatch

Database link name at the local node does not match the global name of the database that the link accesses. Ensure that the GLOBAL_NAMES initialization parameter is set to true and the link name matches the global name.

dblinkuidmismatch

User name of the replication administration user at the local node and the user name at the node corresponding to the database link are not the same. Advanced Replication expects the two users to be the same. Ensure that the user identification of the replication administration user at the local node and the user identification at the node corresponding to the database link are the same.

objectnotgenerated

Object has not been generated at other master sites or is still being generated. Ensure that the object is generated by calling GENERATE_REPLICATION_SUPPORT and DO_DEFERRED_REPCAT_ADMIN for the object at the master definition site.

Usage Notes

The return value of VALIDATE is the number of errors found. The function's OUT parameter returns any errors that are found. In the first interface function, the error_table consists of an array of records. Each record has a VARCHAR2 and a NUMBER in it. The string field contains the error message and the number field contains the Oracle error number.

The second interface is similar except that there are two OUT arrays. A VARCHAR2 array with the error messages and a NUMBER array with the error numbers.