[MDEV-33222] system versioned row_start > row_end prevents inserting mariadb-dump file Created: 2024-01-11  Updated: 2024-01-12

Status: Open
Project: MariaDB Server
Component/s: Versioned Tables
Affects Version/s: 10.11.4, 10.11.6
Fix Version/s: 10.11

Type: Bug Priority: Major
Reporter: Zoltan Tutto Assignee: Aleksey Midenkov
Resolution: Unresolved Votes: 0
Labels: None
Environment:

10.11.4-MariaDB-1:10.11.4+maria~deb11 (mariadb.org binary distribution)
Linux xxxx.local 5.10.0-23-amd64 #1 SMP Debian 5.10.179-2 (2023-07-14) x86_64 GNU/Linux


Attachments: Text File phantom-history-records.txt    

 Description   

The insert of mariadb-dump sql file ends up with error because ROW_START > ROW_END in some records. The dump created on 10.11.4 and import is performed on 10.11.6 server versions.
No errors in server log. We assume the application updates the records with the same value, perhaps in a transaction.
(No more info on it )
Here are the phantom records:

MariaDB [mcatu001]> select gsid, ROW_START, ROW_END from grid_show FOR SYSTEM_TIME ALL WHERE gsid in (25119, 25120) ORDER BY ROW_START;
+-------+----------------------------+----------------------------+
| gsid  | ROW_START                  | ROW_END                    |
+-------+----------------------------+----------------------------+
| 25119 | 2024-01-03 12:08:45.804315 | 2024-01-03 17:08:08.453210 |
| 25120 | 2024-01-03 12:08:45.805367 | 2024-01-03 17:08:08.454756 |
| 25119 | 2024-01-03 17:08:08.453210 | 2024-01-03 17:08:08.370360 |
| 25120 | 2024-01-03 17:08:08.454756 | 2024-01-03 17:08:08.370360 |
+-------+----------------------------+----------------------------+
4 rows in set (0.001 sec) 

(see the attached text file as well).
In "normal" query the rows where row_start > row_end are invisible FOR any particular system time.

The main issue with it is the requirement for dump sql file editing before import.
Thx


Generated at Thu Feb 08 10:37:18 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.