ACE Director Alum Daniel Morgan, founder of Morgan's Library, is scheduling
complimentary technical Workshops on Database Security for the first 30
Oracle Database customers located anywhere in North America, EMEA, LATAM, or
APAC that send an email to
asra_us@oracle.com. Request a Workshop for
your organization today.
Purpose
API to data definition language (DDL) statements from stored procedures and access to operations not available as DDL
Equivalent to SQL ANALYZE TABLE, CLUSTER, or INDEX
dbms_ddl.analyze_object(
type IN VARCHAR2,
schema IN VARCHAR2,
name IN VARCHAR2,
method IN VARCHAR2,
estimate_rows IN NUMBER DEFAULT NULL,
estimate_percent IN NUMBER DEFAULT NULL,
method_opt IN VARCHAR2 DEFAULT NULL,
partname IN VARCHAR2 DEFAULT NULL);
METHOD: ESTIMATE', 'COMPUTE' or 'DELETE'
METHOD_OPT: [ FOR TABLE ],
[ FOR ALL [INDEXED] COLUMNS] [SIZE n], or
[ FOR ALL INDEXES ]
Returns TRUE if the specified DML or DDL trigger is set to fire once
dbms_ddl.is_trigger_fire_once(
trig_owner IN VARCHAR2,
trig_name IN VARCHAR2)
RETURN BOOLEAN;
CREATE TABLE t (
testcol VARCHAR2(20));
CREATE OR REPLACE TRIGGER testtrig
BEFORE UPDATE
ON t
BEGIN
NULL;
END testtrig;
/
set serveroutput on
BEGIN
IF dbms_ddl.is_trigger_fire_once(user, 'testtrig') THEN
dbms_output.put_line('TRUE');
ELSE
dbms_output.put_line('FALSE');
END IF;
END;
/
-- A FALSE will be reported for a trigger when changes are made by a Streams apply process
-- or for changes made by executing one or more Streams apply errors using the EXECUTE_ERROR
-- or EXECUTE_ALL_ERRORS procedures in the DBMS_APPLY_ADM package.
Sets the specified DML or DDL trigger's firing property. Used in replication to keep a downstream trigger from firing.
Overload 1
dbms_ddl.set_trigger_firing_property(
trig_owner IN VARCHAR2,
trig_name IN VARCHAR2,
fire_once IN BOOLEAN);
PRAGMA SUPPLEMENTAL_LOG_DATA(set_trigger_firing_property, AUTO_WITH_COMMIT);
dbms_ddl.set_trigger_firing_property(
trig_owner IN VARCHAR2,
trig_name IN VARCHAR2,
property IN BINARY_INTEGER,
setting IN BOOLEAN);
PRAGMA SUPPLEMENTAL_LOG_DATA(set_trigger_firing_property, AUTO_WITH_COMMIT);