Audit at Oracle

I need help auditing at Oracle. We have a database with many tables, and we want to be able to check every change made to any table in any area. So, all that we want to have in this audit:

  • user who changed
  • a time of change has occurred.
  • old value and new value

so we started creating a trigger that was supposed to audit for any table, but then had problems ...

As I said, we have so many tables, and we cannot create a trigger for each table. Thus, the idea is to create a main trigger that can behave dynamically for any table that triggers the trigger. I tried to do this, but I had no luck ... it seems like Oracle is restricting the trigger environment only to the table that is declared by the code, and not dynamically as we want.

Do you have any idea on how to do this or any other advice to solve this problem?

+3
source share
2 answers

You do not need to write your own triggers.

Oracle . (9i) . (Edit: 10g 11g .)

, firehose - - , / . , , . , , , .

+4

10g, Oracle Fine-Grained Auditing. , .

- FGA , . : .

, , , , . OLD NEW , , - :

  • ( , , )
  • , ?
  • , .

, . CHANGED_TIMESTAMP CHANGED_USER , .

, , , , : NEW . INSERT UPDATE. , . DELETE .

, . DDL (user_tables, user_tab_columns).

+5

Source: https://habr.com/ru/post/1744378/


All Articles