Every table of an application can keep the full history of its rows. The history is switched on per table with "Maintain History". The history of a table is kept in a separate table with the same name in which the first underscore is replaced by `h`, so the history of `bubs_codes` is kept in `bubshcodes`.
A history table has the columns of the table plus five columns of its own:
- The identity of the version.
- The event that created the version: `I` for an insert and `U` for an update.
- The moment from which the version was valid.
- The moment until which the version was valid; `31-12-9999` while it is still valid.
- An indicator that is filled only on the version that is currently valid.
The names of these columns are set per application. In Invantive Estate they are Dutch, such as `h_datum_start` and `h_datum_einde`.
## How Versions Follow Each Other
Every insert and every update writes a version. Sorted by the start, the end of one version lies one second before the start of the next. A gap between two versions appears only when the row was deleted; a delete itself writes no version, it ends the current one.
## Using the History
The history tables can be queried directly, for instance to show the name of a user on the first day of every month. For a query on one moment the [[Invantive Studio/Repository/Concepts/Point in Time|point-in-time views]] are easier, because they show every table and business object as it was at that moment.
The documents and the tables of the technical administration keep no history.