Oracle audit skills used to track DML actions of oracle background databases

Source: Internet
Author: User

The Oracle audit technique is used to track the DML action of the oracle background database create or replace package when is procedure pro_monitor_drop_policy (object_schema in varchar2); procedure when (object_schema in varchar2); procedure when; procedure pro_monitor_add_main; end;/create or replace package body aa_pkg_monitor_business_ SQL is/* truncate table sys. fga_log $; select t. * from dba_fga_audit_trail t; */procedure pro_monitor_drop_policy (object_schema in varchar2) is cursor cur_del is select owner, table_name from dba_tables a where owner = object_schema; begin for v_cur in cur_del loop begin struct (object_schema => v_cur.owner, --- object_name => v_cur.table_name, --- policy_name => v_cur.table_name); exception when others then null; end loop; end pro_monitor_drop_policy; define your procedure pro_monitor_add_policy (object_schema in varchar2) is cursor cur_del is select owner, table_name from dba_tables a where owner = object_schema and. table_name not like 'srp % '; begin for v_cur in cur_del loop begin Schemas (object_schema => v_cur.owner, -- object_name => v_cur.table_name, -- policy_name => v_cur.table_name, rows => 'select, UPDATE, DELETE, INSERT ', enable => true); exception when others then null; end loop; end pro_monitor_add_policy; condition when procedure execution is begin pro_monitor_drop_policy ('ccare '); terminate ('crmpub '); pro_monitor_drop_policy ('ventory'); pro_monitor_drop_policy ('isap '); terminate ('osms'); pro_monitor_drop_policy ('ecare '); pro_monitor_drop_policy ('channel'); end role; begin using your own procedure role is begin role; pro_monitor_add_policy ('ccare'); -- pro_monitor_add_policy ('crmpub '); pro_monitor_add_policy ('ventory '); -- pro_monitor_add_policy ('isap'); --- pro_monitor_add_policy ('osms'); end pro_monitor_add_main; end ;/

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.