Historical Data Action Types
Three action types are recorded in the historical data database table:
create,
update, and
delete.
Create
When an object is created, an entry is added to the historical data database table for the object being created, for each field with a value. The action type for create actions is set to 1. For example:
The historical data table includes an entry for each field that is initialized during the job order creation. As a result, multiple entries with the same ReferenceKey value appear for a single job order.
In the example, two job orders were created:
1. The first job order was created with a description value of Test Description 1, a worktype value of 1, and an id value of JobOrder1.
2. The second job order was created with a description value of Test Description 2, a worktype value of 1, and an id value of JobOrder2.
Update
When an object is updated, an entry is added to the historical data database table for each updated value. For update actions, the action type is set to 2. For example:
In the example, the job order being updated has a UID of 1 in its own database table. This corresponds to the ReferenceKey value of 1 in the historical data database table entry. The job order was updated to have its description value changed to Updated Description, and its id value changed to Updated ID.
Delete
When an object is deleted, a single entry is added to the historical data database table for the object being deleted. The action type for the entry is set to 3. For example:
In the example, a single entry is added to the historical data database table for the deletion that occurred, with the action type set to 3.