K2BAudit Reorganize

Introduction

K2BAudit creates a set of triggers in the application's database. These triggers are associated with Insert, Update, and Delete opeartions performed in audited tables.

K2BAudit Reorganize is an operation that creates those triggers in the database. It should be executed once when K2BAudit is first configured in an environment, and again every time a database reorganization is executed.

The operation can be run from the GeneXus IDE (in design time) or from a command line (when deploying the application).

Execution summary

When this operation is run from the GeneXus IDE, the program will:

  1. Search for audited transactions in the KB.
  2. Create up-to-date procedures for each audited transaction, that generate the triggers for the transaction's table, for each operation an DBMS.
    K2BAuditGeneratedProcedures
    Generated procedures

  3. Update the model definition (attributes and tables) in the Audit Database.
  4. Create the triggers in the database.

When this operation is run as a command line program, the first two steps are not executed. In order to update procedures or auditable transactions, the operation must be run in the GeneXus IDE.