Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Not a Bug
-
N/A
-
None
Description
MariaDB [test]> create or replace table t1 (i int) with system versioning; |
Query OK, 0 rows affected (0.18 sec) |
This does not work:
MariaDB [test]> select * from (select * from t1) drv for system_time as of now(); |
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'system_time as of now()' at line 1 |
The right syntax apparently is
MariaDB [test]> select * from (select * from t1) for system_time as of now() drv; |
Empty set (0.00 sec) |
I want to ensure it's intentional, since the working syntax looks confusing.
|
Test case for copy-pasting |
CREATE TABLE t1 (i INT) WITH SYSTEM VERSIONING; |
SELECT * FROM t1 FOR system_time ALL; |
SELECT * FROM ( SELECT * FROM t1 ) t FOR system_time ALL; |
 |
# Cleanup
|
DROP TABLE t1; |