Patent ID: 8433692

Claim:
A method implemented by a database system, the method comprising: inserting a record into a first table, wherein the record in the first table comprises a primary key field that stores a primary key, a foreign key field that stores a foreign key, and a first field that stores a first value; inserting a record into a first history table, wherein the record in the first history table comprises a field that stores a copy of the primary key, a field that stores a name of the foreign key field, and a field that stores a copy of the foreign key; inserting a record into a second table, wherein the record in the second table comprises a primary key field that stores a primary key, and a field that stores second data; inserting a record into a second history table, wherein the record in the second history table comprises a field that stores a copy of the second data; updating the first value stored in the first field of the record in the first table in response to the database system receiving a first structured query language (SQL) statement from a customer relationship management (CRM) application; inserting a first record into the first history table in response to the first SQL statement, wherein the first record in the first history table comprises a field that stores a copy of the primary key of the record in the first table, a field that stores a copy of the first value after it is updated, a field that stores a name of the first field, and a first date field; wherein the first date field stores either the date when the first SQL statement was received by the database system, the date of the day that immediately follows the date when the first SQL statement was received by the database system, or a date that was entered into a field of a user interface.