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, 139 of 179


CREATE_USER_PARM_VALUE function

This function predefines deployment template parameter values for specific users. For example, if you want to predefine the region parameter as WEST for user 33456, then you would use the this function.

Any values specified with this function take precedence over default values specified for the template parameter. The number returned by this function is used internally by Oracle to manage deployment templates.

Syntax

DBMS_REPCAT_RGT.CREATE_USER_PARM_VALUE (
   refresh_template_name    IN   VARCHAR2, 
   parameter_name           IN   VARCHAR2,
   user_name                IN   VARCHAR2,
   parm_value               IN   CLOB := NULL)
  return NUMBER;

Parameters

Table 8-263 CREATE_USER_PARM_VALUE Function Parameters
Parameter  Description 
refresh_template_
name
 

Specifies the name of the deployment template that contains the parameter you are creating a user parameter value for. 

parameter_name
 

Name of the template parameter that you are defining a user parameter value for. 

user_name
 

Specifies the name of the user that you are predefining a user parameter value for. 

parm_value
 

The predefined parameter value that will be used during the instantiation process initiated by the specified user. 

Exceptions

Table 8-264 CREATE_USER_PARM_VALUE Function Exceptions
Exception  Description 
miss_refresh_
template
 

Specified deployment template name is invalid or missing. 

dupl_user_parm_
values
 

A parameter value for the specified user, parameter, and deployment template has already been defined. Query the DBA_REPCAT_USER_PARM_VALUES view for a listing of existing user parameter values. 

miss_template_parm
 

Specified deployment template parameter name is invalid or missing. 

miss_user
 

Specified user name is invalid or missing. 

Returns

Table 8-265 CREATE_USER_PARM_VALUE Function Returns
Return Value  Description 

<system-generated number

System-generated number used internally by Oracle. 

Usage Notes

Because the CREATE_USER_PARM_VALUE function utilizes a CLOB, you must use the DBMS_LOB package when using the this function. The following example illustrates how to use the DBMS_LOB package with the CREATE_USER_PARM_VALUE function:

DECLARE
   tempstring VARCHAR2(100);
   templob CLOB;
   a NUMBER;
BEGIN
   DBMS_LOB.CREATETEMPORARY(templob, TRUE, DBMS_LOB.SESSION);
   tempstring := 'REGION 20';
   DBMS_LOB.WRITE(templob, length(tempstring), 1, tempstring);
   a := DBMS_REPCAT_RGT.CREATE_USER_PARM_VALUE(
        refresh_template_name => 'rgt_personnel',
        parameter_name => 'region',
        user_name => 'BOB',
        user_parm_value => templob);
   DBMS_LOB.FREETEMPORARY(templob);
END;
/

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