1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Parser: moved 'for system_time' before alias

Due to standard (see 7.6 <table reference>).
This commit is contained in:
Aleksey Midenkov
2017-07-23 17:07:56 +03:00
parent a5ec9fc1b4
commit aa292666cc
9 changed files with 40 additions and 32 deletions

View File

@@ -33,11 +33,11 @@ ancestors
as
(
select e.emp_id, e.name, e.mgr, e.salary
from emp as e for system_time as of timestamp @ts_1
from emp for system_time as of timestamp @ts_1 as e
where name = 'bill'
union
select e.emp_id, e.name, e.mgr, e.salary
from emp as e for system_time as of timestamp @ts_1,
from emp for system_time as of timestamp @ts_1 as e,
ancestors as a
where e.mgr = a.emp_id
)
@@ -51,11 +51,11 @@ ancestors
as
(
select e.emp_id, e.name, e.mgr, e.salary
from emp as e for system_time as of timestamp @ts_2
from emp for system_time as of timestamp @ts_2 as e
where name = 'bill'
union
select e.emp_id, e.name, e.mgr, e.salary
from emp as e for system_time as of timestamp @ts_2,
from emp for system_time as of timestamp @ts_2 as e,
ancestors as a
where e.mgr = a.emp_id
)