ALTER VIEW

Recompile or redefine a view.

Syntax:

   ALTER VIEW [schema.]view COMPILE;

   ALTER VIEW [schema.]view ADD out_of_line_constraint;

   ALTER VIEW [schema.]view MODIFY CONSTRAINT constraint {RELY | NORELY};

   ALTER VIEW [schema.]view DROP CONSTRAINT constraint;

   ALTER VIEW [schema.]view DROP PRIMARY KEY

   ALTER VIEW [schema.]view UNIQUE (column [,column,…])

When a constraint is in NOVALIDATE mode, Oracle does not enforce it and does not take it into account for query rewrite. If you specify RELY Oracle will still not enforce the constraint but will take it into account for query rewrite.

An alternative to ALTER VIEW COMPILE is the built-in pl/sql package DBMS_UTILITY

“The truth is not always the same as the majority decision” - Pope John XXII

Related Commands:

CREATE VIEW
DROP VIEW

Related Views:

 DBA_VIEWS            ALL_VIEWS            USER_VIEWS
 DBA_MVIEWS           ALL_MVIEWS           USER_MVIEWS
 V$FIXED_VIEW_DEFINITION 
 V$RESERVED_WORDS


© Copyright SS64.com 1999-2014
Some rights reserved