ALLBASE/SQL Reference Manual (36216-90216)

Chapter 2 91
Using ALLBASE/SQL
Auditing DBEnvironments
Careful use of savepoints can decrease the amount of time locks are held, and reduces the
need to resubmit transactions because part of a transaction was unsuccessful.
Set the maximum number of transactions (
MaxTransactions
) and timeout limit
parameters correctly. If
MaxTransactions
is too low, transactions will wait for no reason.
However, the overall throughput of the DBEnvironment may be reduced if
MaxTransactions
is too high. If the timeout limit is too low, transactions will abort, but if
set too high, the session might wait indefinitely for a transaction slot.
Auditing DBEnvironments
Audit DBEnvironments are created with SQL statements that allow you to generate audit
log records. Audit log records contain information that allows you to group log records for
analysis with SQLAudit. The database operations you might analyze are UPDATE, INSERT,
or DELETE operations, perhaps for security reasons.
Audit log records contain identifiers such as table names in contrast to non-audit database
log records which contain identifiers such as page references and data. Audit log records
are generated in addition to non-audit database log records.
A unique audit name specifies an audit DBEnvironment. Audit elements indicate which
ALLBASE/SQL statement types generate audit log records. By default, statements that
change
data
generate audit log records (INSERT, UPDATE, and DELETE statements); this
default can also be specified explicitly by the
DATA AUDIT ELEMENTS
parameter. You can
also optionally specify that log comment, data definition, authorization, or section
statements (creation and deletion of sections) generate audit log records.
The Audit Tool, SQLAudit, is introduced below. SQLAudit is fully described in the
ALLBASE/SQL Database Administration Guide. The ALLBASE/SQL Database
Administration Guide describes how to create audit DBEnvironments and how to select
records for audit. Chapter 10 , “SQL Statements A - D,” and Chapters 11 and 12 of this
manual contain the detailed syntax to create audit DBEnvironments and partitions.
Partitions in Audit DBEnvironments
Partitions are divisions of DBEnvironments that contain one or more tables processed by
SQLAudit as a unit. Partitions are specified in CREATE PARTITION, CREATE TABLE, and
ALTER TABLE statements. In addition, default partition and comment partition numbers
can optionally be specified.