IP Library Granted Patent US 11,886,424
Granted Patent B2
US 11,886,424 · App. 17/481,644 · Granted Jan 30, 2024

System versioned table with transactional system time

Inventors: Bernhard Scheirle (Leimen, DE); Andreas Tonder (Weinheim, DE); Carsten Thiel (Heidelberg, DE); Guenter Radestock (Karlsruhe, DE); Thomas Legler (Walldorf, DE); Martin Heidel (Walldorf, DE); Robert Schulze (Walldorf, DE); Joern Schmidt (Walldorf, DE); Rolando Blanco (Waterloo, CA)
Assignee: SAP SE
G06F16/2379
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,886,424
App. No.
17/481,644
Granted
Jan 30, 2024
Kind
B2
Abstract

A method may include receiving a first transaction inserting a record into a database and a second transaction deleting the record from the database. A validity period for the record may be determined based on a first commit time at which the first transaction is committed and a second commit time at which the second transaction is committed. A current table and/or a history table of a system versioned table may be updated to include the record based on the validity period of the record. One or more temporal operations may be performed based on the system versioned table. For example, a time travel operation may be performed to retrieve, based on the system versioned table, one or more records that are valid at a given point in time. Related systems and computer program products are also provided.

Claims (33)

1. A system, comprising:

at least one data processor; and

at least one memory storing instructions which, when executed by the at least one data processor, cause operations comprising:

receiving a first transaction inserting a record into a database and a second transaction deleting the record from the database;

determining, based at least on a first commit time at which the first transaction is committed and a second commit time at which the second transaction is committed, a validity period of the record; and

updating, based at least on the validity period of the record, a current table and/or a history table of a system versioned table to include the record, wherein the updating comprises moving the record from the current table to the history table upon an expiration of the validity period.

2. The system of claim 1 , wherein the validity period comprises a valid-from timestamp and a valid-to timestamp.

3. The system of claim 2 , wherein the valid-from timestamp corresponds to the first commit time of the first transaction inserting the record, and wherein the valid-to timestamp corresponds to the second commit time of the second transaction deleting the record.

4. The system of claim 1 , wherein the record is stored in the current table during the validity period of the record.

5. The system of claim 1 , wherein the record is omitted from the history table in response to the first transaction and the second transaction being a same transaction.

6. The system of claim 1 , wherein the validity period is determined based on the first commit time of the first transaction and the second commit time of the second transaction instead of a first start time of the first transaction and/or a second start time of the second transaction.

7. The system of claim 1 , wherein the operations further comprise:

performing, based at least on the system versioned table, a time travel operation by at least identifying one or more data records that are valid at a given point in time.

8. The system of claim 1 , wherein the operations further comprise:

determining, based at least on the system versioned table, a version history of the record.

9. The system of claim 1 , wherein the database comprises an in-memory column-oriented relational database.

10. A computer-implemented method, comprising:

receiving a first transaction inserting a record into a database and a second transaction deleting the record from the database;

determining, based at least on a first commit time at which the first transaction is committed and a second commit time at which the second transaction is committed, a validity period of the record; and

updating, based at least on the validity period of the record, a current table and/or a history table of a system versioned table to include the record, wherein the updating comprises moving the record from the current table to the history table upon an expiration of the validity period.

11. The method of claim 10 , wherein the validity period comprises a valid-from timestamp and a valid-to timestamp.

12. The method of claim 11 , wherein the valid-from timestamp corresponds to the first commit time of the first transaction inserting the record, and wherein the valid-to timestamp corresponds to the second commit time of the second transaction deleting the record.

13. The method of claim 10 , wherein the record is omitted from the history table in response to the first transaction and the second transaction being a same transaction.

14. The method of claim 10 , wherein the validity period is determined based on the first commit time of the first transaction and the second commit time of the second transaction instead of a first start time of the first transaction and/or a second start time of the second transaction.

15. The method of claim 10 , wherein the operations further comprise:

performing, based at least on the system versioned table, a time travel operation by at least identifying one or more data records that are valid at a given point in time.

16. The method of claim 10 , wherein the operations further comprise:

determining, based at least on the system versioned table, a version history of the record.

17. The method of claim 10 , wherein the database comprises an in-memory column-oriented relational database.

18. A non-transitory computer readable medium storing instructions, which when executed by at least one data processor, result in operations comprising:

receiving a first transaction inserting a record into a database and a second transaction deleting the record from the database;

determining, based at least on a first commit time at which the first transaction is committed and a second commit time at which the second transaction is committed, a validity period of the record; and

updating, based at least on the validity period of the record, a current table and/or a history table of a system versioned table to include the record, wherein the updating comprises moving the record from the current table to the history table upon an expiration of the validity period.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 22, 2021
From: SCHEIRLE, BERNHARD; TONDER, ANDREAS; THIEL, CARSTEN; RADESTOCK, GUENTER; LEGLER, THOMAS; HEIDEL, MARTIN; SCHULZE, ROBERT; SCHMIDT, JOERN; BLANCO, ROLANDO
To: SAP SE
Reel/Frame 057562/0153 →
Continuity (1)
Related Publication 20230086162A1 · Mar 23, 2023