 |
|
Oracle Tips by Burleson |
Chapter 11 Oracle Fine Grained Auditing
was owned by CLAIM_SCHEMA. To find out what the
user saw at the time, we can issue the following statements in
sequence.
alter session
set current_schema = CLAIM_SCHEMA;
This will instruct all the queries to be based
on the CLAIM_SCHMEA schema.
execute
dbms_flashback.enable_at_system_change_number(1553620)
This will place the reference time to that
point in the past, mentioned by SCN. Now we will execute the SQL
query.
select paid_amount from claims where claim_id =
1234567;
This will return 1200. The queries are repeated
as many times as required to find the values at that time. At the
end of the session, we can disable the flashback session by:
execute dbms_flashback.disable
Now all the queries will select the data as of
now, not from the past.
This technique can be extended to become a
self-sufficient querying system. Consider the following:
set linesize 4000
The above text is
an excerpt from
the bestselling book:
Oracle
Privacy Security Auditing.
It's only $39.95 and has an
download of working security scripts:
This is the only authoritative
book on Oracle Security, Oracle Privacy, and Oracle Auditing written
by two of the world’s leading Oracle Security experts.
This indispensable book is only $39.95 and has an
download of working security scripts:
http://rampant-books.com/book_2003_2_audit.htm
Download your Oracle scripts now:
www.oracle-script.com
The
definitive Oracle Script collection for every Oracle professional DBA
|
|