Wednesday, August 7, 2019

WITH READ ONLY in VIEWS

Denying DML Operations.

You can ensure that no DML operations occur by adding the WITH READ ONLY option to your view definition.

Example:

SQL>CREATE OR REPLACE VIEW empvu10(employee_number, employee_name, job_title)
  AS SELECT empno, ename, job
           FROM emp
        WHERE deptno = 10
           WITH READ ONLY;

View created.

Any attempt to perform a DML on any row in the view will result in Oracle Server error ORA-01752.

No comments:

Post a Comment

AME (Approval Management Engine)

AME (Approval Management Engine) : AME Stands for Oracle Approval Management Engine. AME is a self service web application that enables...