Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Duplicate
-
None
-
None
Description
The PERIOD FOR syntax registers a special constraint on a table. There can be only one period per table and it can be designated to be part of a unique index 'without overlaps'. However, it seems that it is impossible to track periods in the information schema:
- The PERIOD FOR constraint translates to a CHECK constraint that just gets the same name as the period name (unless that name is already occupied in the table, in which case a new name gets generated). The CHECK constraint appears to be defined in CHECK_CONSTRAINTS as 'from_time_column < to_time_column', but there is no mention of this being a PERIOD in any of the information schema tables.
- It is possible to register a unique index using the period 'WITHOUT OVERLAPS'. We will find the period's two columns to be part of the unique index in STATISTICS, but there is no mention of the WITHOUT OVERLAPS modifier.
Attachments
Issue Links
- duplicates
-
MDEV-22597 Add views for periods in information_schema
- Closed