Database auditing for bulk operations
View Patent ↗A method facilitates auditing of database transactions by maintaining logical consistency between a source database table and a shadow database table. A bulk command is received that specifies edits to a plurality of rows in the source database table. The bulk command is executed on the source database table. The shadow database table is queried to obtain an indication of the plurality of rows edited by the bulk command. The indication is stored as part of an audit trail for the source database table.
1. A system for facilitating auditing of database transactions, the system comprising:
a replication module configured to maintain logical consistency between a source database table and a shadow database table;
a database management module configured to
receive a bulk command that specifies edits to a plurality of rows in the source database table, wherein the bulk command specifies a partition-level operation for the source database table;
execute the bulk command on the source database table;
a row level tracking module configured to
query the shadow database table to obtain an indication of the plurality of rows edited by the bulk command; and
store the indication as part of an audit trail for the source database table.
2. The system of claim 1 , wherein the database management module is configured to perform the bulk command using hardware and wherein the row level tracking module is configured to query the shadow table in parallel using different hardware.
3. The system of claim 1 , wherein the partition-level operation includes at least one operation from the group consisting of a truncate and a delete.
4. The system of claim 1 , wherein the database management module is further configured to query the shadow table based upon ranges of values in columns that correspond to a partition of the source database table.
5. The system of claim 1 , wherein bulk command specifies a plurality of rows from the source database table independent based upon a value in a column field.
6. The system of claim 1 , wherein the bulk command specifies a plurality of rows from the source database table based upon a value in a column field.