Oracle9i Supplied PL/SQL Packages and Types Reference
Release 1 (9.0.1)

Part Number A89852-02
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback

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

DBMS_RLS , 2 of 13


ADD_POLICY Procedure

This procedure adds a fine-grained access control policy to a table or view.

The procedure causes the current transaction, if any, to commit before the operation is carried out. However, this does not cause a commit first if it is inside a DDL event trigger.

See Also:

Usage Notes 

A commit is also performed at the end of the operation.

Syntax

DBMS_RLS.ADD_POLICY (
   object_schema   IN VARCHAR2 := NULL,
   object_name     IN VARCHAR2,
   policy_name     IN VARCHAR2,
   function_schema IN VARCHAR2 := NULL,
   policy_function IN VARCHAR2,
   statement_types IN VARCHAR2 := NULL,
   update_check    IN BOOLEAN  := FALSE,
   enable          IN BOOLEAN  := TRUE);

Parameters

Table 56-2 ADD_POLICY Procedure Parameters
Parameter  Description 
object_schema
 

Schema containing the table or view (logon user, if NULL). 

object_name
 

Name of table or view to which the policy is added. 

policy_name
 

Name of policy to be added. It must be unique for the same table or view. 

function_schema
 

Schema of the policy function (logon user, if NULL). 

policy_function
 

Name of a function which generates a predicate for the policy. If the function is defined within a package, then the name of the package must be present. 

statement_types
 

Statement types that the policy will apply. It can be any combination of SELECT, INSERT, UPDATE, and DELETE. The default is to apply to all of these types. 

update_check
 

Optional argument for INSERT or UPDATE statement types. The default is FALSE. Setting update_check to TRUE causes the server to also check the policy against the value after insert or update. 

enable
 

Indicates if the policy is enabled when it is added. The default is TRUE 

Usage Notes


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

All Rights Reserved.
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback