1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

precedence bugfixing

fix printing precedence for BETWEEN, LIKE/ESCAPE, REGEXP, IN
don't use precedence for printing CASE/WHEN/THEN/ELSE/END

fix parsing precedence of BETWEEN, LIKE/ESCAPE, REGEXP, IN
support predicate arguments for IN, BETWEEN, SOUNDS LIKE, LIKE/ESCAPE,
REGEXP

use %nonassoc for unary operators

fix parsing of IS TRUE/FALSE/UNKNOWN/NULL

remove parser_precedence test as superseded by the precedence test
This commit is contained in:
Sergei Golubchik
2020-10-05 12:50:51 +02:00
parent 7f974e5ad3
commit 05a878c139
16 changed files with 349 additions and 1490 deletions

View File

@ -1351,3 +1351,17 @@ create function fs() returns serial return 1;
create table t1 ( id serial );
show create table t1;
drop table t1;
#
# BETWEEN syntax
#
create or replace view v1 as select 1 between (2 between 3 and 4) and 5;
Select view_definition from information_schema.views where table_schema='test' and table_name='v1';
create or replace view v1 as select 1 between (2 in (3,4)) and 5;
Select view_definition from information_schema.views where table_schema='test' and table_name='v1';
create or replace view v1 as select 1 between (2 like 3) and 4;
Select view_definition from information_schema.views where table_schema='test' and table_name='v1';
create or replace view v1 as select 1 not between (2 like 3) and 4;
Select view_definition from information_schema.views where table_schema='test' and table_name='v1';
drop view v1;