mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
for now, remove FOR SYSTEM_TIME at the end of the query
non-standard, redundant, potentially risky in the future, hides bugs. See #383, #384, #385 Fixed a parser bug where SELECT * FROM (t1 join t2) FOR SYSTEM_TIME ... was not an error.
This commit is contained in:
@ -42,31 +42,32 @@ where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary dept_id name
|
||||
1 10 bill 2000 10 accounting
|
||||
select * from emp e, dept d
|
||||
select * from
|
||||
emp for system_time from timestamp @ts_1 to timestamp @ts_2 e,
|
||||
dept for system_time from timestamp @ts_1 to timestamp @ts_2 d
|
||||
where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id
|
||||
for system_time from timestamp @ts_1 to timestamp @ts_2;
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary sys_trx_start sys_trx_end dept_id name sys_trx_start sys_trx_end
|
||||
set statement versioning_asof_timestamp=@ts_0 for
|
||||
select * from emp e, dept d
|
||||
where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id
|
||||
for system_time as of timestamp @ts_0;
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary dept_id name
|
||||
set statement versioning_asof_timestamp=@ts_1 for
|
||||
select * from emp e, dept d
|
||||
where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id
|
||||
for system_time as of timestamp @ts_1;
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary dept_id name
|
||||
set statement versioning_asof_timestamp=@ts_2 for
|
||||
select * from emp e, dept d
|
||||
where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id
|
||||
for system_time as of timestamp @ts_2;
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary dept_id name
|
||||
1 10 bill 1000 10 accounting
|
||||
set statement versioning_asof_timestamp=@ts_3 for
|
||||
select * from emp e, dept d
|
||||
where d.dept_id = 10
|
||||
and d.dept_id = e.dept_id
|
||||
for system_time as of timestamp @ts_3;
|
||||
and d.dept_id = e.dept_id;
|
||||
emp_id dept_id name salary dept_id name
|
||||
1 10 bill 2000 10 accounting
|
||||
drop table emp, dept;
|
||||
|
Reference in New Issue
Block a user