From b078e2970cfb79c040d42e518413e0c325adde43 Mon Sep 17 00:00:00 2001 From: Marios Trivyzas Date: Mon, 26 Nov 2018 14:02:02 +0100 Subject: [PATCH] SQL: Implement null safe equality operator `<=>` (#35873) This operator handles nulls in different way than the normal `=`. If one of the operants is `null` and the other not it returns `false`. If both operants are `null` it returns `true`. Therefore in contrary to `=`, which returns `null` if at least one of the operants is `null`, this one never returns `null` as a result. Closes: #35871 --- .../sql/functions/operators.asciidoc | 14 +- .../sql/qa/src/main/resources/agg.csv-spec | 2 +- .../sql/qa/src/main/resources/docs.csv-spec | 20 + x-pack/plugin/sql/src/main/antlr/SqlBase.g4 | 5 +- .../plugin/sql/src/main/antlr/SqlBase.tokens | 78 +- .../sql/src/main/antlr/SqlBaseLexer.tokens | 76 +- .../whitelist/InternalSqlScriptUtils.java | 4 + .../comparison/BinaryComparisonProcessor.java | 21 +- .../operator/comparison/Comparisons.java | 8 + .../operator/comparison/NullEquals.java | 41 + .../xpack/sql/optimizer/Optimizer.java | 19 +- .../xpack/sql/parser/ExpressionBuilder.java | 3 + .../xpack/sql/parser/SqlBaseLexer.java | 703 +++++++++--------- .../xpack/sql/parser/SqlBaseParser.java | 61 +- .../xpack/sql/planner/QueryTranslator.java | 3 +- .../xpack/sql/plugin/sql_whitelist.txt | 1 + .../BinaryComparisonProcessorTests.java | 21 +- .../xpack/sql/optimizer/OptimizerTests.java | 94 ++- .../xpack/sql/parser/ExpressionTests.java | 9 + 19 files changed, 697 insertions(+), 486 deletions(-) create mode 100644 x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/NullEquals.java diff --git a/docs/reference/sql/functions/operators.asciidoc b/docs/reference/sql/functions/operators.asciidoc index aae9d47ec7e..81b0963fd59 100644 --- a/docs/reference/sql/functions/operators.asciidoc +++ b/docs/reference/sql/functions/operators.asciidoc @@ -12,7 +12,19 @@ Boolean operator for comparing against one or multiple expressions. include-tagged::{sql-specs}/filter.sql-spec[whereFieldEquality] -------------------------------------------------- -* Inequality (`<>` or `!=` or `<=>`) +* Null safe Equality (`<=>`) + +["source","sql",subs="attributes,callouts,macros"] +-------------------------------------------------- +include-tagged::{sql-specs}/docs.csv-spec[nullEqualsCompareWithNull] +-------------------------------------------------- + +["source","sql",subs="attributes,callouts,macros"] +-------------------------------------------------- +include-tagged::{sql-specs}/docs.csv-spec[nullEqualsCompareTwoNulls] +-------------------------------------------------- + +* Inequality (`<>` or `!=`) ["source","sql",subs="attributes,callouts,macros"] -------------------------------------------------- diff --git a/x-pack/plugin/sql/qa/src/main/resources/agg.csv-spec b/x-pack/plugin/sql/qa/src/main/resources/agg.csv-spec index 23902516c3b..79656fea582 100644 --- a/x-pack/plugin/sql/qa/src/main/resources/agg.csv-spec +++ b/x-pack/plugin/sql/qa/src/main/resources/agg.csv-spec @@ -136,4 +136,4 @@ null |null |null |null |null | 2 |2 |38 |2 |2.0 |100.0 |NaN |NaN 3 |3 |51 |3 |3.0 |100.0 |NaN |NaN 4 |4 |72 |4 |4.0 |0.0 |NaN |NaN -; \ No newline at end of file +; diff --git a/x-pack/plugin/sql/qa/src/main/resources/docs.csv-spec b/x-pack/plugin/sql/qa/src/main/resources/docs.csv-spec index 9c069972ec3..1202a26c6b5 100644 --- a/x-pack/plugin/sql/qa/src/main/resources/docs.csv-spec +++ b/x-pack/plugin/sql/qa/src/main/resources/docs.csv-spec @@ -1619,3 +1619,23 @@ SELECT NULLIF('elastic', 'elastic') AS "nullif"; null // end::nullIfReturnNull ; + +nullEqualsCompareWithNull +// tag::nullEqualsCompareWithNull +SELECT 'elastic' <=> null AS "equals"; + + equals +--------------- +false +// end::nullEqualsCompareWithNull +; + +nullEqualsCompareTwoNulls +// tag::nullEqualsCompareTwoNulls +SELECT null <=> null AS "equals"; + + equals +--------------- +true +// end::nullEqualsCompareTwoNulls +; diff --git a/x-pack/plugin/sql/src/main/antlr/SqlBase.g4 b/x-pack/plugin/sql/src/main/antlr/SqlBase.g4 index 20d9c74dd6d..f6e49b0cf66 100644 --- a/x-pack/plugin/sql/src/main/antlr/SqlBase.g4 +++ b/x-pack/plugin/sql/src/main/antlr/SqlBase.g4 @@ -277,7 +277,7 @@ constant ; comparisonOperator - : EQ | NEQ | LT | LTE | GT | GTE + : EQ | NULLEQ | NEQ | LT | LTE | GT | GTE ; booleanValue @@ -452,7 +452,8 @@ GUID_ESC: '{GUID'; ESC_END: '}'; EQ : '='; -NEQ : '<>' | '!=' | '<=>'; +NULLEQ: '<=>'; +NEQ : '<>' | '!='; LT : '<'; LTE : '<='; GT : '>'; diff --git a/x-pack/plugin/sql/src/main/antlr/SqlBase.tokens b/x-pack/plugin/sql/src/main/antlr/SqlBase.tokens index f8232bf886e..b815fd4d0cf 100644 --- a/x-pack/plugin/sql/src/main/antlr/SqlBase.tokens +++ b/x-pack/plugin/sql/src/main/antlr/SqlBase.tokens @@ -96,32 +96,33 @@ TIMESTAMP_ESC=95 GUID_ESC=96 ESC_END=97 EQ=98 -NEQ=99 -LT=100 -LTE=101 -GT=102 -GTE=103 -PLUS=104 -MINUS=105 -ASTERISK=106 -SLASH=107 -PERCENT=108 -CONCAT=109 -DOT=110 -PARAM=111 -STRING=112 -INTEGER_VALUE=113 -DECIMAL_VALUE=114 -IDENTIFIER=115 -DIGIT_IDENTIFIER=116 -TABLE_IDENTIFIER=117 -QUOTED_IDENTIFIER=118 -BACKQUOTED_IDENTIFIER=119 -SIMPLE_COMMENT=120 -BRACKETED_COMMENT=121 -WS=122 -UNRECOGNIZED=123 -DELIMITER=124 +NULLEQ=99 +NEQ=100 +LT=101 +LTE=102 +GT=103 +GTE=104 +PLUS=105 +MINUS=106 +ASTERISK=107 +SLASH=108 +PERCENT=109 +CONCAT=110 +DOT=111 +PARAM=112 +STRING=113 +INTEGER_VALUE=114 +DECIMAL_VALUE=115 +IDENTIFIER=116 +DIGIT_IDENTIFIER=117 +TABLE_IDENTIFIER=118 +QUOTED_IDENTIFIER=119 +BACKQUOTED_IDENTIFIER=120 +SIMPLE_COMMENT=121 +BRACKETED_COMMENT=122 +WS=123 +UNRECOGNIZED=124 +DELIMITER=125 '('=1 ')'=2 ','=3 @@ -220,15 +221,16 @@ DELIMITER=124 '{GUID'=96 '}'=97 '='=98 -'<'=100 -'<='=101 -'>'=102 -'>='=103 -'+'=104 -'-'=105 -'*'=106 -'/'=107 -'%'=108 -'||'=109 -'.'=110 -'?'=111 +'<=>'=99 +'<'=101 +'<='=102 +'>'=103 +'>='=104 +'+'=105 +'-'=106 +'*'=107 +'/'=108 +'%'=109 +'||'=110 +'.'=111 +'?'=112 diff --git a/x-pack/plugin/sql/src/main/antlr/SqlBaseLexer.tokens b/x-pack/plugin/sql/src/main/antlr/SqlBaseLexer.tokens index c05044ba0b1..ba6b3a69e8e 100644 --- a/x-pack/plugin/sql/src/main/antlr/SqlBaseLexer.tokens +++ b/x-pack/plugin/sql/src/main/antlr/SqlBaseLexer.tokens @@ -96,31 +96,32 @@ TIMESTAMP_ESC=95 GUID_ESC=96 ESC_END=97 EQ=98 -NEQ=99 -LT=100 -LTE=101 -GT=102 -GTE=103 -PLUS=104 -MINUS=105 -ASTERISK=106 -SLASH=107 -PERCENT=108 -CONCAT=109 -DOT=110 -PARAM=111 -STRING=112 -INTEGER_VALUE=113 -DECIMAL_VALUE=114 -IDENTIFIER=115 -DIGIT_IDENTIFIER=116 -TABLE_IDENTIFIER=117 -QUOTED_IDENTIFIER=118 -BACKQUOTED_IDENTIFIER=119 -SIMPLE_COMMENT=120 -BRACKETED_COMMENT=121 -WS=122 -UNRECOGNIZED=123 +NULLEQ=99 +NEQ=100 +LT=101 +LTE=102 +GT=103 +GTE=104 +PLUS=105 +MINUS=106 +ASTERISK=107 +SLASH=108 +PERCENT=109 +CONCAT=110 +DOT=111 +PARAM=112 +STRING=113 +INTEGER_VALUE=114 +DECIMAL_VALUE=115 +IDENTIFIER=116 +DIGIT_IDENTIFIER=117 +TABLE_IDENTIFIER=118 +QUOTED_IDENTIFIER=119 +BACKQUOTED_IDENTIFIER=120 +SIMPLE_COMMENT=121 +BRACKETED_COMMENT=122 +WS=123 +UNRECOGNIZED=124 '('=1 ')'=2 ','=3 @@ -219,15 +220,16 @@ UNRECOGNIZED=123 '{GUID'=96 '}'=97 '='=98 -'<'=100 -'<='=101 -'>'=102 -'>='=103 -'+'=104 -'-'=105 -'*'=106 -'/'=107 -'%'=108 -'||'=109 -'.'=110 -'?'=111 +'<=>'=99 +'<'=101 +'<='=102 +'>'=103 +'>='=104 +'+'=105 +'-'=106 +'*'=107 +'/'=108 +'%'=109 +'||'=110 +'.'=111 +'?'=112 diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/function/scalar/whitelist/InternalSqlScriptUtils.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/function/scalar/whitelist/InternalSqlScriptUtils.java index 22aefd73c5e..924cbc09cb1 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/function/scalar/whitelist/InternalSqlScriptUtils.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/function/scalar/whitelist/InternalSqlScriptUtils.java @@ -92,6 +92,10 @@ public final class InternalSqlScriptUtils { return BinaryComparisonOperation.EQ.apply(left, right); } + public static Boolean nulleq(Object left, Object right) { + return BinaryComparisonOperation.NULLEQ.apply(left, right); + } + public static Boolean neq(Object left, Object right) { return BinaryComparisonOperation.NEQ.apply(left, right); } diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessor.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessor.java index 7c7983cf2c1..7064562e65f 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessor.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessor.java @@ -15,10 +15,11 @@ import java.io.IOException; import java.util.function.BiFunction; public class BinaryComparisonProcessor extends FunctionalBinaryProcessor { - + public enum BinaryComparisonOperation implements PredicateBiFunction { EQ(Comparisons::eq, "=="), + NULLEQ(Comparisons::nulleq, "<=>"), NEQ(Comparisons::neq, "!="), GT(Comparisons::gt, ">"), GTE(Comparisons::gte, ">="), @@ -38,6 +39,14 @@ public class BinaryComparisonProcessor extends FunctionalBinaryProcessor} operator + */ +public class NullEquals extends BinaryComparison { + + public NullEquals(Location location, Expression left, Expression right) { + super(location, left, right, BinaryComparisonOperation.NULLEQ); + } + + @Override + protected NodeInfo info() { + return NodeInfo.create(this, NullEquals::new, left(), right()); + } + + @Override + protected NullEquals replaceChildren(Expression newLeft, Expression newRight) { + return new NullEquals(location(), newLeft, newRight); + } + + @Override + public NullEquals swapLeftAndRight() { + return new NullEquals(location(), right(), left()); + } + + @Override + public boolean nullable() { + return false; + } +} diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/optimizer/Optimizer.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/optimizer/Optimizer.java index 492a27894a1..ba68eb8afb3 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/optimizer/Optimizer.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/optimizer/Optimizer.java @@ -56,6 +56,7 @@ import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.In; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThan; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThanOrEqual; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NotEquals; +import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NullEquals; import org.elasticsearch.xpack.sql.plan.logical.Aggregate; import org.elasticsearch.xpack.sql.plan.logical.EsRelation; import org.elasticsearch.xpack.sql.plan.logical.Filter; @@ -1378,6 +1379,14 @@ public class Optimizer extends RuleExecutor { return TRUE; } } + if (bc instanceof NullEquals) { + if (l.semanticEquals(r)) { + return TRUE; + } + if (Expressions.isNull(r)) { + return new IsNull(bc.location(), l); + } + } // false for equality if (bc instanceof NotEquals || bc instanceof GreaterThan || bc instanceof LessThan) { @@ -1432,7 +1441,7 @@ public class Optimizer extends RuleExecutor { // combine conjunction private Expression propagate(And and) { List ranges = new ArrayList<>(); - List equals = new ArrayList<>(); + List equals = new ArrayList<>(); List exps = new ArrayList<>(); boolean changed = false; @@ -1440,11 +1449,11 @@ public class Optimizer extends RuleExecutor { for (Expression ex : Predicates.splitAnd(and)) { if (ex instanceof Range) { ranges.add((Range) ex); - } else if (ex instanceof Equals) { - Equals otherEq = (Equals) ex; + } else if (ex instanceof Equals || ex instanceof NullEquals) { + BinaryComparison otherEq = (BinaryComparison) ex; // equals on different values evaluate to FALSE if (otherEq.right().foldable()) { - for (Equals eq : equals) { + for (BinaryComparison eq : equals) { // cannot evaluate equals so skip it if (!eq.right().foldable()) { continue; @@ -1469,7 +1478,7 @@ public class Optimizer extends RuleExecutor { } // check - for (Equals eq : equals) { + for (BinaryComparison eq : equals) { // cannot evaluate equals so skip it if (!eq.right().foldable()) { continue; diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/ExpressionBuilder.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/ExpressionBuilder.java index 1f13e8e74dd..4863fd1f2e8 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/ExpressionBuilder.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/ExpressionBuilder.java @@ -51,6 +51,7 @@ import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.In; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThan; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThanOrEqual; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NotEquals; +import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NullEquals; import org.elasticsearch.xpack.sql.expression.predicate.regex.Like; import org.elasticsearch.xpack.sql.expression.predicate.regex.LikePattern; import org.elasticsearch.xpack.sql.expression.predicate.regex.RLike; @@ -181,6 +182,8 @@ abstract class ExpressionBuilder extends IdentifierBuilder { switch (op.getSymbol().getType()) { case SqlBaseParser.EQ: return new Equals(loc, left, right); + case SqlBaseParser.NULLEQ: + return new NullEquals(loc, left, right); case SqlBaseParser.NEQ: return new NotEquals(loc, left, right); case SqlBaseParser.LT: diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseLexer.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseLexer.java index d35808d1b93..bdf9a8360ff 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseLexer.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseLexer.java @@ -30,12 +30,12 @@ class SqlBaseLexer extends Lexer { SYS=76, TABLE=77, TABLES=78, TEXT=79, TRUE=80, TO=81, TYPE=82, TYPES=83, USING=84, VERIFY=85, WHERE=86, WITH=87, YEAR=88, YEARS=89, ESCAPE_ESC=90, FUNCTION_ESC=91, LIMIT_ESC=92, DATE_ESC=93, TIME_ESC=94, TIMESTAMP_ESC=95, - GUID_ESC=96, ESC_END=97, EQ=98, NEQ=99, LT=100, LTE=101, GT=102, GTE=103, - PLUS=104, MINUS=105, ASTERISK=106, SLASH=107, PERCENT=108, CONCAT=109, - DOT=110, PARAM=111, STRING=112, INTEGER_VALUE=113, DECIMAL_VALUE=114, - IDENTIFIER=115, DIGIT_IDENTIFIER=116, TABLE_IDENTIFIER=117, QUOTED_IDENTIFIER=118, - BACKQUOTED_IDENTIFIER=119, SIMPLE_COMMENT=120, BRACKETED_COMMENT=121, - WS=122, UNRECOGNIZED=123; + GUID_ESC=96, ESC_END=97, EQ=98, NULLEQ=99, NEQ=100, LT=101, LTE=102, GT=103, + GTE=104, PLUS=105, MINUS=106, ASTERISK=107, SLASH=108, PERCENT=109, CONCAT=110, + DOT=111, PARAM=112, STRING=113, INTEGER_VALUE=114, DECIMAL_VALUE=115, + IDENTIFIER=116, DIGIT_IDENTIFIER=117, TABLE_IDENTIFIER=118, QUOTED_IDENTIFIER=119, + BACKQUOTED_IDENTIFIER=120, SIMPLE_COMMENT=121, BRACKETED_COMMENT=122, + WS=123, UNRECOGNIZED=124; public static String[] modeNames = { "DEFAULT_MODE" }; @@ -53,11 +53,11 @@ class SqlBaseLexer extends Lexer { "SELECT", "SHOW", "SYS", "TABLE", "TABLES", "TEXT", "TRUE", "TO", "TYPE", "TYPES", "USING", "VERIFY", "WHERE", "WITH", "YEAR", "YEARS", "ESCAPE_ESC", "FUNCTION_ESC", "LIMIT_ESC", "DATE_ESC", "TIME_ESC", "TIMESTAMP_ESC", - "GUID_ESC", "ESC_END", "EQ", "NEQ", "LT", "LTE", "GT", "GTE", "PLUS", - "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", "STRING", - "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", "TABLE_IDENTIFIER", - "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "EXPONENT", "DIGIT", "LETTER", - "SIMPLE_COMMENT", "BRACKETED_COMMENT", "WS", "UNRECOGNIZED" + "GUID_ESC", "ESC_END", "EQ", "NULLEQ", "NEQ", "LT", "LTE", "GT", "GTE", + "PLUS", "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", + "STRING", "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", + "TABLE_IDENTIFIER", "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "EXPONENT", + "DIGIT", "LETTER", "SIMPLE_COMMENT", "BRACKETED_COMMENT", "WS", "UNRECOGNIZED" }; private static final String[] _LITERAL_NAMES = { @@ -75,8 +75,8 @@ class SqlBaseLexer extends Lexer { "'SELECT'", "'SHOW'", "'SYS'", "'TABLE'", "'TABLES'", "'TEXT'", "'TRUE'", "'TO'", "'TYPE'", "'TYPES'", "'USING'", "'VERIFY'", "'WHERE'", "'WITH'", "'YEAR'", "'YEARS'", "'{ESCAPE'", "'{FN'", "'{LIMIT'", "'{D'", "'{T'", - "'{TS'", "'{GUID'", "'}'", "'='", null, "'<'", "'<='", "'>'", "'>='", - "'+'", "'-'", "'*'", "'/'", "'%'", "'||'", "'.'", "'?'" + "'{TS'", "'{GUID'", "'}'", "'='", "'<=>'", null, "'<'", "'<='", "'>'", + "'>='", "'+'", "'-'", "'*'", "'/'", "'%'", "'||'", "'.'", "'?'" }; private static final String[] _SYMBOLIC_NAMES = { null, null, null, null, null, "ALL", "ANALYZE", "ANALYZED", "AND", "ANY", @@ -91,11 +91,11 @@ class SqlBaseLexer extends Lexer { "SELECT", "SHOW", "SYS", "TABLE", "TABLES", "TEXT", "TRUE", "TO", "TYPE", "TYPES", "USING", "VERIFY", "WHERE", "WITH", "YEAR", "YEARS", "ESCAPE_ESC", "FUNCTION_ESC", "LIMIT_ESC", "DATE_ESC", "TIME_ESC", "TIMESTAMP_ESC", - "GUID_ESC", "ESC_END", "EQ", "NEQ", "LT", "LTE", "GT", "GTE", "PLUS", - "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", "STRING", - "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", "TABLE_IDENTIFIER", - "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "SIMPLE_COMMENT", "BRACKETED_COMMENT", - "WS", "UNRECOGNIZED" + "GUID_ESC", "ESC_END", "EQ", "NULLEQ", "NEQ", "LT", "LTE", "GT", "GTE", + "PLUS", "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", + "STRING", "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", + "TABLE_IDENTIFIER", "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "SIMPLE_COMMENT", + "BRACKETED_COMMENT", "WS", "UNRECOGNIZED" }; public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES); @@ -152,7 +152,7 @@ class SqlBaseLexer extends Lexer { public ATN getATN() { return _ATN; } public static final String _serializedATN = - "\3\u0430\ud6d1\u8206\uad2d\u4417\uaef1\u8d80\uaadd\2}\u0402\b\1\4\2\t"+ + "\3\u0430\ud6d1\u8206\uad2d\u4417\uaef1\u8d80\uaadd\2~\u0405\b\1\4\2\t"+ "\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13"+ "\t\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22"+ "\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27\4\30\t\30\4\31\t\31"+ @@ -165,338 +165,339 @@ class SqlBaseLexer extends Lexer { "\4U\tU\4V\tV\4W\tW\4X\tX\4Y\tY\4Z\tZ\4[\t[\4\\\t\\\4]\t]\4^\t^\4_\t_\4"+ "`\t`\4a\ta\4b\tb\4c\tc\4d\td\4e\te\4f\tf\4g\tg\4h\th\4i\ti\4j\tj\4k\t"+ "k\4l\tl\4m\tm\4n\tn\4o\to\4p\tp\4q\tq\4r\tr\4s\ts\4t\tt\4u\tu\4v\tv\4"+ - "w\tw\4x\tx\4y\ty\4z\tz\4{\t{\4|\t|\4}\t}\4~\t~\4\177\t\177\3\2\3\2\3\3"+ - "\3\3\3\4\3\4\3\5\3\5\3\6\3\6\3\6\3\6\3\7\3\7\3\7\3\7\3\7\3\7\3\7\3\7\3"+ - "\b\3\b\3\b\3\b\3\b\3\b\3\b\3\b\3\b\3\t\3\t\3\t\3\t\3\n\3\n\3\n\3\n\3\13"+ - "\3\13\3\13\3\f\3\f\3\f\3\f\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\16\3\16\3"+ - "\16\3\17\3\17\3\17\3\17\3\17\3\20\3\20\3\20\3\20\3\20\3\20\3\20\3\20\3"+ - "\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\22\3\22\3\22\3\22\3\22\3"+ - "\22\3\22\3\22\3\23\3\23\3\23\3\23\3\23\3\23\3\23\3\23\3\24\3\24\3\24\3"+ - "\24\3\25\3\25\3\25\3\25\3\25\3\26\3\26\3\26\3\26\3\26\3\26\3\27\3\27\3"+ - "\27\3\27\3\27\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\31\3\31\3"+ - "\31\3\31\3\31\3\31\3\31\3\31\3\31\3\32\3\32\3\32\3\32\3\32\3\32\3\32\3"+ - "\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\34\3\34\3\34\3"+ - "\34\3\34\3\34\3\34\3\35\3\35\3\35\3\35\3\35\3\35\3\35\3\35\3\36\3\36\3"+ - "\36\3\36\3\36\3\36\3\36\3\36\3\37\3\37\3\37\3\37\3\37\3\37\3 \3 \3 \3"+ - " \3 \3 \3!\3!\3!\3!\3!\3!\3!\3\"\3\"\3\"\3\"\3\"\3#\3#\3#\3#\3#\3$\3$"+ - "\3$\3$\3$\3$\3$\3$\3$\3$\3%\3%\3%\3%\3%\3%\3%\3%\3%\3&\3&\3&\3&\3&\3&"+ - "\3\'\3\'\3\'\3\'\3\'\3\'\3\'\3(\3(\3(\3(\3(\3)\3)\3)\3)\3)\3)\3*\3*\3"+ - "*\3+\3+\3+\3+\3+\3+\3,\3,\3,\3,\3,\3,\3,\3,\3,\3-\3-\3-\3.\3.\3.\3.\3"+ - ".\3/\3/\3/\3/\3/\3\60\3\60\3\60\3\60\3\60\3\61\3\61\3\61\3\61\3\61\3\62"+ - "\3\62\3\62\3\62\3\62\3\62\3\63\3\63\3\63\3\63\3\63\3\63\3\63\3\64\3\64"+ - "\3\64\3\64\3\64\3\64\3\65\3\65\3\65\3\65\3\65\3\65\3\65\3\66\3\66\3\66"+ - "\3\66\3\66\3\66\3\66\3\66\3\67\3\67\3\67\3\67\3\67\3\67\38\38\38\38\3"+ - "8\38\38\39\39\39\39\39\39\39\39\3:\3:\3:\3:\3;\3;\3;\3;\3;\3<\3<\3<\3"+ - "<\3<\3<\3=\3=\3=\3>\3>\3>\3>\3>\3>\3>\3>\3>\3>\3?\3?\3?\3@\3@\3@\3@\3"+ - "@\3@\3A\3A\3A\3A\3A\3A\3B\3B\3B\3B\3B\3B\3B\3C\3C\3C\3C\3C\3C\3C\3C\3"+ - "C\3D\3D\3D\3D\3D\3E\3E\3E\3E\3E\3E\3F\3F\3F\3F\3F\3F\3G\3G\3G\3G\3G\3"+ - "G\3H\3H\3H\3H\3H\3H\3H\3H\3I\3I\3I\3I\3I\3I\3I\3J\3J\3J\3J\3J\3J\3J\3"+ - "J\3K\3K\3K\3K\3K\3K\3K\3L\3L\3L\3L\3L\3M\3M\3M\3M\3N\3N\3N\3N\3N\3N\3"+ - "O\3O\3O\3O\3O\3O\3O\3P\3P\3P\3P\3P\3Q\3Q\3Q\3Q\3Q\3R\3R\3R\3S\3S\3S\3"+ - "S\3S\3T\3T\3T\3T\3T\3T\3U\3U\3U\3U\3U\3U\3V\3V\3V\3V\3V\3V\3V\3W\3W\3"+ - "W\3W\3W\3W\3X\3X\3X\3X\3X\3Y\3Y\3Y\3Y\3Y\3Z\3Z\3Z\3Z\3Z\3Z\3[\3[\3[\3"+ - "[\3[\3[\3[\3[\3\\\3\\\3\\\3\\\3]\3]\3]\3]\3]\3]\3]\3^\3^\3^\3_\3_\3_\3"+ - "`\3`\3`\3`\3a\3a\3a\3a\3a\3a\3b\3b\3c\3c\3d\3d\3d\3d\3d\3d\3d\5d\u0343"+ - "\nd\3e\3e\3f\3f\3f\3g\3g\3h\3h\3h\3i\3i\3j\3j\3k\3k\3l\3l\3m\3m\3n\3n"+ - "\3n\3o\3o\3p\3p\3q\3q\3q\3q\7q\u0364\nq\fq\16q\u0367\13q\3q\3q\3r\6r\u036c"+ - "\nr\rr\16r\u036d\3s\6s\u0371\ns\rs\16s\u0372\3s\3s\7s\u0377\ns\fs\16s"+ - "\u037a\13s\3s\3s\6s\u037e\ns\rs\16s\u037f\3s\6s\u0383\ns\rs\16s\u0384"+ - "\3s\3s\7s\u0389\ns\fs\16s\u038c\13s\5s\u038e\ns\3s\3s\3s\3s\6s\u0394\n"+ - "s\rs\16s\u0395\3s\3s\5s\u039a\ns\3t\3t\5t\u039e\nt\3t\3t\3t\7t\u03a3\n"+ - "t\ft\16t\u03a6\13t\3u\3u\3u\3u\6u\u03ac\nu\ru\16u\u03ad\3v\3v\3v\6v\u03b3"+ - "\nv\rv\16v\u03b4\3w\3w\3w\3w\7w\u03bb\nw\fw\16w\u03be\13w\3w\3w\3x\3x"+ - "\3x\3x\7x\u03c6\nx\fx\16x\u03c9\13x\3x\3x\3y\3y\5y\u03cf\ny\3y\6y\u03d2"+ - "\ny\ry\16y\u03d3\3z\3z\3{\3{\3|\3|\3|\3|\7|\u03de\n|\f|\16|\u03e1\13|"+ - "\3|\5|\u03e4\n|\3|\5|\u03e7\n|\3|\3|\3}\3}\3}\3}\3}\7}\u03f0\n}\f}\16"+ - "}\u03f3\13}\3}\3}\3}\3}\3}\3~\6~\u03fb\n~\r~\16~\u03fc\3~\3~\3\177\3\177"+ - "\3\u03f1\2\u0080\3\3\5\4\7\5\t\6\13\7\r\b\17\t\21\n\23\13\25\f\27\r\31"+ - "\16\33\17\35\20\37\21!\22#\23%\24\'\25)\26+\27-\30/\31\61\32\63\33\65"+ - "\34\67\359\36;\37= ?!A\"C#E$G%I&K\'M(O)Q*S+U,W-Y.[/]\60_\61a\62c\63e\64"+ - "g\65i\66k\67m8o9q:s;u{?}@\177A\u0081B\u0083C\u0085D\u0087E\u0089"+ - "F\u008bG\u008dH\u008fI\u0091J\u0093K\u0095L\u0097M\u0099N\u009bO\u009d"+ - "P\u009fQ\u00a1R\u00a3S\u00a5T\u00a7U\u00a9V\u00abW\u00adX\u00afY\u00b1"+ - "Z\u00b3[\u00b5\\\u00b7]\u00b9^\u00bb_\u00bd`\u00bfa\u00c1b\u00c3c\u00c5"+ - "d\u00c7e\u00c9f\u00cbg\u00cdh\u00cfi\u00d1j\u00d3k\u00d5l\u00d7m\u00d9"+ - "n\u00dbo\u00ddp\u00dfq\u00e1r\u00e3s\u00e5t\u00e7u\u00e9v\u00ebw\u00ed"+ - "x\u00efy\u00f1\2\u00f3\2\u00f5\2\u00f7z\u00f9{\u00fb|\u00fd}\3\2\f\3\2"+ - "))\4\2BBaa\5\2<\3\2\2\2\u01b1\u01b2\7H\2\2\u01b2\u01b3\7K\2\2\u01b3"+ - "\u01b4\7T\2\2\u01b4\u01b5\7U\2\2\u01b5\u01b6\7V\2\2\u01b6@\3\2\2\2\u01b7"+ - "\u01b8\7H\2\2\u01b8\u01b9\7Q\2\2\u01b9\u01ba\7T\2\2\u01ba\u01bb\7O\2\2"+ - "\u01bb\u01bc\7C\2\2\u01bc\u01bd\7V\2\2\u01bdB\3\2\2\2\u01be\u01bf\7H\2"+ - "\2\u01bf\u01c0\7T\2\2\u01c0\u01c1\7Q\2\2\u01c1\u01c2\7O\2\2\u01c2D\3\2"+ - "\2\2\u01c3\u01c4\7H\2\2\u01c4\u01c5\7W\2\2\u01c5\u01c6\7N\2\2\u01c6\u01c7"+ - "\7N\2\2\u01c7F\3\2\2\2\u01c8\u01c9\7H\2\2\u01c9\u01ca\7W\2\2\u01ca\u01cb"+ - "\7P\2\2\u01cb\u01cc\7E\2\2\u01cc\u01cd\7V\2\2\u01cd\u01ce\7K\2\2\u01ce"+ - "\u01cf\7Q\2\2\u01cf\u01d0\7P\2\2\u01d0\u01d1\7U\2\2\u01d1H\3\2\2\2\u01d2"+ - "\u01d3\7I\2\2\u01d3\u01d4\7T\2\2\u01d4\u01d5\7C\2\2\u01d5\u01d6\7R\2\2"+ - "\u01d6\u01d7\7J\2\2\u01d7\u01d8\7X\2\2\u01d8\u01d9\7K\2\2\u01d9\u01da"+ - "\7\\\2\2\u01daJ\3\2\2\2\u01db\u01dc\7I\2\2\u01dc\u01dd\7T\2\2\u01dd\u01de"+ - "\7Q\2\2\u01de\u01df\7W\2\2\u01df\u01e0\7R\2\2\u01e0L\3\2\2\2\u01e1\u01e2"+ - "\7J\2\2\u01e2\u01e3\7C\2\2\u01e3\u01e4\7X\2\2\u01e4\u01e5\7K\2\2\u01e5"+ - "\u01e6\7P\2\2\u01e6\u01e7\7I\2\2\u01e7N\3\2\2\2\u01e8\u01e9\7J\2\2\u01e9"+ - "\u01ea\7Q\2\2\u01ea\u01eb\7W\2\2\u01eb\u01ec\7T\2\2\u01ecP\3\2\2\2\u01ed"+ - "\u01ee\7J\2\2\u01ee\u01ef\7Q\2\2\u01ef\u01f0\7W\2\2\u01f0\u01f1\7T\2\2"+ - "\u01f1\u01f2\7U\2\2\u01f2R\3\2\2\2\u01f3\u01f4\7K\2\2\u01f4\u01f5\7P\2"+ - "\2\u01f5T\3\2\2\2\u01f6\u01f7\7K\2\2\u01f7\u01f8\7P\2\2\u01f8\u01f9\7"+ - "P\2\2\u01f9\u01fa\7G\2\2\u01fa\u01fb\7T\2\2\u01fbV\3\2\2\2\u01fc\u01fd"+ - "\7K\2\2\u01fd\u01fe\7P\2\2\u01fe\u01ff\7V\2\2\u01ff\u0200\7G\2\2\u0200"+ - "\u0201\7T\2\2\u0201\u0202\7X\2\2\u0202\u0203\7C\2\2\u0203\u0204\7N\2\2"+ - "\u0204X\3\2\2\2\u0205\u0206\7K\2\2\u0206\u0207\7U\2\2\u0207Z\3\2\2\2\u0208"+ - "\u0209\7L\2\2\u0209\u020a\7Q\2\2\u020a\u020b\7K\2\2\u020b\u020c\7P\2\2"+ - "\u020c\\\3\2\2\2\u020d\u020e\7N\2\2\u020e\u020f\7C\2\2\u020f\u0210\7U"+ - "\2\2\u0210\u0211\7V\2\2\u0211^\3\2\2\2\u0212\u0213\7N\2\2\u0213\u0214"+ - "\7G\2\2\u0214\u0215\7H\2\2\u0215\u0216\7V\2\2\u0216`\3\2\2\2\u0217\u0218"+ - "\7N\2\2\u0218\u0219\7K\2\2\u0219\u021a\7M\2\2\u021a\u021b\7G\2\2\u021b"+ - "b\3\2\2\2\u021c\u021d\7N\2\2\u021d\u021e\7K\2\2\u021e\u021f\7O\2\2\u021f"+ - "\u0220\7K\2\2\u0220\u0221\7V\2\2\u0221d\3\2\2\2\u0222\u0223\7O\2\2\u0223"+ - "\u0224\7C\2\2\u0224\u0225\7R\2\2\u0225\u0226\7R\2\2\u0226\u0227\7G\2\2"+ - "\u0227\u0228\7F\2\2\u0228f\3\2\2\2\u0229\u022a\7O\2\2\u022a\u022b\7C\2"+ - "\2\u022b\u022c\7V\2\2\u022c\u022d\7E\2\2\u022d\u022e\7J\2\2\u022eh\3\2"+ - "\2\2\u022f\u0230\7O\2\2\u0230\u0231\7K\2\2\u0231\u0232\7P\2\2\u0232\u0233"+ - "\7W\2\2\u0233\u0234\7V\2\2\u0234\u0235\7G\2\2\u0235j\3\2\2\2\u0236\u0237"+ - "\7O\2\2\u0237\u0238\7K\2\2\u0238\u0239\7P\2\2\u0239\u023a\7W\2\2\u023a"+ - "\u023b\7V\2\2\u023b\u023c\7G\2\2\u023c\u023d\7U\2\2\u023dl\3\2\2\2\u023e"+ - "\u023f\7O\2\2\u023f\u0240\7Q\2\2\u0240\u0241\7P\2\2\u0241\u0242\7V\2\2"+ - "\u0242\u0243\7J\2\2\u0243n\3\2\2\2\u0244\u0245\7O\2\2\u0245\u0246\7Q\2"+ - "\2\u0246\u0247\7P\2\2\u0247\u0248\7V\2\2\u0248\u0249\7J\2\2\u0249\u024a"+ - "\7U\2\2\u024ap\3\2\2\2\u024b\u024c\7P\2\2\u024c\u024d\7C\2\2\u024d\u024e"+ - "\7V\2\2\u024e\u024f\7W\2\2\u024f\u0250\7T\2\2\u0250\u0251\7C\2\2\u0251"+ - "\u0252\7N\2\2\u0252r\3\2\2\2\u0253\u0254\7P\2\2\u0254\u0255\7Q\2\2\u0255"+ - "\u0256\7V\2\2\u0256t\3\2\2\2\u0257\u0258\7P\2\2\u0258\u0259\7W\2\2\u0259"+ - "\u025a\7N\2\2\u025a\u025b\7N\2\2\u025bv\3\2\2\2\u025c\u025d\7P\2\2\u025d"+ - "\u025e\7W\2\2\u025e\u025f\7N\2\2\u025f\u0260\7N\2\2\u0260\u0261\7U\2\2"+ - "\u0261x\3\2\2\2\u0262\u0263\7Q\2\2\u0263\u0264\7P\2\2\u0264z\3\2\2\2\u0265"+ - "\u0266\7Q\2\2\u0266\u0267\7R\2\2\u0267\u0268\7V\2\2\u0268\u0269\7K\2\2"+ - "\u0269\u026a\7O\2\2\u026a\u026b\7K\2\2\u026b\u026c\7\\\2\2\u026c\u026d"+ - "\7G\2\2\u026d\u026e\7F\2\2\u026e|\3\2\2\2\u026f\u0270\7Q\2\2\u0270\u0271"+ - "\7T\2\2\u0271~\3\2\2\2\u0272\u0273\7Q\2\2\u0273\u0274\7T\2\2\u0274\u0275"+ - "\7F\2\2\u0275\u0276\7G\2\2\u0276\u0277\7T\2\2\u0277\u0080\3\2\2\2\u0278"+ - "\u0279\7Q\2\2\u0279\u027a\7W\2\2\u027a\u027b\7V\2\2\u027b\u027c\7G\2\2"+ - "\u027c\u027d\7T\2\2\u027d\u0082\3\2\2\2\u027e\u027f\7R\2\2\u027f\u0280"+ - "\7C\2\2\u0280\u0281\7T\2\2\u0281\u0282\7U\2\2\u0282\u0283\7G\2\2\u0283"+ - "\u0284\7F\2\2\u0284\u0084\3\2\2\2\u0285\u0286\7R\2\2\u0286\u0287\7J\2"+ - "\2\u0287\u0288\7[\2\2\u0288\u0289\7U\2\2\u0289\u028a\7K\2\2\u028a\u028b"+ - "\7E\2\2\u028b\u028c\7C\2\2\u028c\u028d\7N\2\2\u028d\u0086\3\2\2\2\u028e"+ - "\u028f\7R\2\2\u028f\u0290\7N\2\2\u0290\u0291\7C\2\2\u0291\u0292\7P\2\2"+ - "\u0292\u0088\3\2\2\2\u0293\u0294\7T\2\2\u0294\u0295\7K\2\2\u0295\u0296"+ - "\7I\2\2\u0296\u0297\7J\2\2\u0297\u0298\7V\2\2\u0298\u008a\3\2\2\2\u0299"+ - "\u029a\7T\2\2\u029a\u029b\7N\2\2\u029b\u029c\7K\2\2\u029c\u029d\7M\2\2"+ - "\u029d\u029e\7G\2\2\u029e\u008c\3\2\2\2\u029f\u02a0\7S\2\2\u02a0\u02a1"+ - "\7W\2\2\u02a1\u02a2\7G\2\2\u02a2\u02a3\7T\2\2\u02a3\u02a4\7[\2\2\u02a4"+ - "\u008e\3\2\2\2\u02a5\u02a6\7U\2\2\u02a6\u02a7\7E\2\2\u02a7\u02a8\7J\2"+ - "\2\u02a8\u02a9\7G\2\2\u02a9\u02aa\7O\2\2\u02aa\u02ab\7C\2\2\u02ab\u02ac"+ - "\7U\2\2\u02ac\u0090\3\2\2\2\u02ad\u02ae\7U\2\2\u02ae\u02af\7G\2\2\u02af"+ - "\u02b0\7E\2\2\u02b0\u02b1\7Q\2\2\u02b1\u02b2\7P\2\2\u02b2\u02b3\7F\2\2"+ - "\u02b3\u0092\3\2\2\2\u02b4\u02b5\7U\2\2\u02b5\u02b6\7G\2\2\u02b6\u02b7"+ - "\7E\2\2\u02b7\u02b8\7Q\2\2\u02b8\u02b9\7P\2\2\u02b9\u02ba\7F\2\2\u02ba"+ - "\u02bb\7U\2\2\u02bb\u0094\3\2\2\2\u02bc\u02bd\7U\2\2\u02bd\u02be\7G\2"+ - "\2\u02be\u02bf\7N\2\2\u02bf\u02c0\7G\2\2\u02c0\u02c1\7E\2\2\u02c1\u02c2"+ - "\7V\2\2\u02c2\u0096\3\2\2\2\u02c3\u02c4\7U\2\2\u02c4\u02c5\7J\2\2\u02c5"+ - "\u02c6\7Q\2\2\u02c6\u02c7\7Y\2\2\u02c7\u0098\3\2\2\2\u02c8\u02c9\7U\2"+ - "\2\u02c9\u02ca\7[\2\2\u02ca\u02cb\7U\2\2\u02cb\u009a\3\2\2\2\u02cc\u02cd"+ - "\7V\2\2\u02cd\u02ce\7C\2\2\u02ce\u02cf\7D\2\2\u02cf\u02d0\7N\2\2\u02d0"+ - "\u02d1\7G\2\2\u02d1\u009c\3\2\2\2\u02d2\u02d3\7V\2\2\u02d3\u02d4\7C\2"+ - "\2\u02d4\u02d5\7D\2\2\u02d5\u02d6\7N\2\2\u02d6\u02d7\7G\2\2\u02d7\u02d8"+ - "\7U\2\2\u02d8\u009e\3\2\2\2\u02d9\u02da\7V\2\2\u02da\u02db\7G\2\2\u02db"+ - "\u02dc\7Z\2\2\u02dc\u02dd\7V\2\2\u02dd\u00a0\3\2\2\2\u02de\u02df\7V\2"+ - "\2\u02df\u02e0\7T\2\2\u02e0\u02e1\7W\2\2\u02e1\u02e2\7G\2\2\u02e2\u00a2"+ - "\3\2\2\2\u02e3\u02e4\7V\2\2\u02e4\u02e5\7Q\2\2\u02e5\u00a4\3\2\2\2\u02e6"+ - "\u02e7\7V\2\2\u02e7\u02e8\7[\2\2\u02e8\u02e9\7R\2\2\u02e9\u02ea\7G\2\2"+ - "\u02ea\u00a6\3\2\2\2\u02eb\u02ec\7V\2\2\u02ec\u02ed\7[\2\2\u02ed\u02ee"+ - "\7R\2\2\u02ee\u02ef\7G\2\2\u02ef\u02f0\7U\2\2\u02f0\u00a8\3\2\2\2\u02f1"+ - "\u02f2\7W\2\2\u02f2\u02f3\7U\2\2\u02f3\u02f4\7K\2\2\u02f4\u02f5\7P\2\2"+ - "\u02f5\u02f6\7I\2\2\u02f6\u00aa\3\2\2\2\u02f7\u02f8\7X\2\2\u02f8\u02f9"+ - "\7G\2\2\u02f9\u02fa\7T\2\2\u02fa\u02fb\7K\2\2\u02fb\u02fc\7H\2\2\u02fc"+ - "\u02fd\7[\2\2\u02fd\u00ac\3\2\2\2\u02fe\u02ff\7Y\2\2\u02ff\u0300\7J\2"+ - "\2\u0300\u0301\7G\2\2\u0301\u0302\7T\2\2\u0302\u0303\7G\2\2\u0303\u00ae"+ - "\3\2\2\2\u0304\u0305\7Y\2\2\u0305\u0306\7K\2\2\u0306\u0307\7V\2\2\u0307"+ - "\u0308\7J\2\2\u0308\u00b0\3\2\2\2\u0309\u030a\7[\2\2\u030a\u030b\7G\2"+ - "\2\u030b\u030c\7C\2\2\u030c\u030d\7T\2\2\u030d\u00b2\3\2\2\2\u030e\u030f"+ - "\7[\2\2\u030f\u0310\7G\2\2\u0310\u0311\7C\2\2\u0311\u0312\7T\2\2\u0312"+ - "\u0313\7U\2\2\u0313\u00b4\3\2\2\2\u0314\u0315\7}\2\2\u0315\u0316\7G\2"+ - "\2\u0316\u0317\7U\2\2\u0317\u0318\7E\2\2\u0318\u0319\7C\2\2\u0319\u031a"+ - "\7R\2\2\u031a\u031b\7G\2\2\u031b\u00b6\3\2\2\2\u031c\u031d\7}\2\2\u031d"+ - "\u031e\7H\2\2\u031e\u031f\7P\2\2\u031f\u00b8\3\2\2\2\u0320\u0321\7}\2"+ - "\2\u0321\u0322\7N\2\2\u0322\u0323\7K\2\2\u0323\u0324\7O\2\2\u0324\u0325"+ - "\7K\2\2\u0325\u0326\7V\2\2\u0326\u00ba\3\2\2\2\u0327\u0328\7}\2\2\u0328"+ - "\u0329\7F\2\2\u0329\u00bc\3\2\2\2\u032a\u032b\7}\2\2\u032b\u032c\7V\2"+ - "\2\u032c\u00be\3\2\2\2\u032d\u032e\7}\2\2\u032e\u032f\7V\2\2\u032f\u0330"+ - "\7U\2\2\u0330\u00c0\3\2\2\2\u0331\u0332\7}\2\2\u0332\u0333\7I\2\2\u0333"+ - "\u0334\7W\2\2\u0334\u0335\7K\2\2\u0335\u0336\7F\2\2\u0336\u00c2\3\2\2"+ - "\2\u0337\u0338\7\177\2\2\u0338\u00c4\3\2\2\2\u0339\u033a\7?\2\2\u033a"+ - "\u00c6\3\2\2\2\u033b\u033c\7>\2\2\u033c\u0343\7@\2\2\u033d\u033e\7#\2"+ - "\2\u033e\u0343\7?\2\2\u033f\u0340\7>\2\2\u0340\u0341\7?\2\2\u0341\u0343"+ - "\7@\2\2\u0342\u033b\3\2\2\2\u0342\u033d\3\2\2\2\u0342\u033f\3\2\2\2\u0343"+ - "\u00c8\3\2\2\2\u0344\u0345\7>\2\2\u0345\u00ca\3\2\2\2\u0346\u0347\7>\2"+ - "\2\u0347\u0348\7?\2\2\u0348\u00cc\3\2\2\2\u0349\u034a\7@\2\2\u034a\u00ce"+ - "\3\2\2\2\u034b\u034c\7@\2\2\u034c\u034d\7?\2\2\u034d\u00d0\3\2\2\2\u034e"+ - "\u034f\7-\2\2\u034f\u00d2\3\2\2\2\u0350\u0351\7/\2\2\u0351\u00d4\3\2\2"+ - "\2\u0352\u0353\7,\2\2\u0353\u00d6\3\2\2\2\u0354\u0355\7\61\2\2\u0355\u00d8"+ - "\3\2\2\2\u0356\u0357\7\'\2\2\u0357\u00da\3\2\2\2\u0358\u0359\7~\2\2\u0359"+ - "\u035a\7~\2\2\u035a\u00dc\3\2\2\2\u035b\u035c\7\60\2\2\u035c\u00de\3\2"+ - "\2\2\u035d\u035e\7A\2\2\u035e\u00e0\3\2\2\2\u035f\u0365\7)\2\2\u0360\u0364"+ - "\n\2\2\2\u0361\u0362\7)\2\2\u0362\u0364\7)\2\2\u0363\u0360\3\2\2\2\u0363"+ - "\u0361\3\2\2\2\u0364\u0367\3\2\2\2\u0365\u0363\3\2\2\2\u0365\u0366\3\2"+ - "\2\2\u0366\u0368\3\2\2\2\u0367\u0365\3\2\2\2\u0368\u0369\7)\2\2\u0369"+ - "\u00e2\3\2\2\2\u036a\u036c\5\u00f3z\2\u036b\u036a\3\2\2\2\u036c\u036d"+ - "\3\2\2\2\u036d\u036b\3\2\2\2\u036d\u036e\3\2\2\2\u036e\u00e4\3\2\2\2\u036f"+ - "\u0371\5\u00f3z\2\u0370\u036f\3\2\2\2\u0371\u0372\3\2\2\2\u0372\u0370"+ - "\3\2\2\2\u0372\u0373\3\2\2\2\u0373\u0374\3\2\2\2\u0374\u0378\5\u00ddo"+ - "\2\u0375\u0377\5\u00f3z\2\u0376\u0375\3\2\2\2\u0377\u037a\3\2\2\2\u0378"+ - "\u0376\3\2\2\2\u0378\u0379\3\2\2\2\u0379\u039a\3\2\2\2\u037a\u0378\3\2"+ - "\2\2\u037b\u037d\5\u00ddo\2\u037c\u037e\5\u00f3z\2\u037d\u037c\3\2\2\2"+ - "\u037e\u037f\3\2\2\2\u037f\u037d\3\2\2\2\u037f\u0380\3\2\2\2\u0380\u039a"+ - "\3\2\2\2\u0381\u0383\5\u00f3z\2\u0382\u0381\3\2\2\2\u0383\u0384\3\2\2"+ - "\2\u0384\u0382\3\2\2\2\u0384\u0385\3\2\2\2\u0385\u038d\3\2\2\2\u0386\u038a"+ - "\5\u00ddo\2\u0387\u0389\5\u00f3z\2\u0388\u0387\3\2\2\2\u0389\u038c\3\2"+ - "\2\2\u038a\u0388\3\2\2\2\u038a\u038b\3\2\2\2\u038b\u038e\3\2\2\2\u038c"+ - "\u038a\3\2\2\2\u038d\u0386\3\2\2\2\u038d\u038e\3\2\2\2\u038e\u038f\3\2"+ - "\2\2\u038f\u0390\5\u00f1y\2\u0390\u039a\3\2\2\2\u0391\u0393\5\u00ddo\2"+ - "\u0392\u0394\5\u00f3z\2\u0393\u0392\3\2\2\2\u0394\u0395\3\2\2\2\u0395"+ - "\u0393\3\2\2\2\u0395\u0396\3\2\2\2\u0396\u0397\3\2\2\2\u0397\u0398\5\u00f1"+ - "y\2\u0398\u039a\3\2\2\2\u0399\u0370\3\2\2\2\u0399\u037b\3\2\2\2\u0399"+ - "\u0382\3\2\2\2\u0399\u0391\3\2\2\2\u039a\u00e6\3\2\2\2\u039b\u039e\5\u00f5"+ - "{\2\u039c\u039e\7a\2\2\u039d\u039b\3\2\2\2\u039d\u039c\3\2\2\2\u039e\u03a4"+ - "\3\2\2\2\u039f\u03a3\5\u00f5{\2\u03a0\u03a3\5\u00f3z\2\u03a1\u03a3\t\3"+ - "\2\2\u03a2\u039f\3\2\2\2\u03a2\u03a0\3\2\2\2\u03a2\u03a1\3\2\2\2\u03a3"+ - "\u03a6\3\2\2\2\u03a4\u03a2\3\2\2\2\u03a4\u03a5\3\2\2\2\u03a5\u00e8\3\2"+ - "\2\2\u03a6\u03a4\3\2\2\2\u03a7\u03ab\5\u00f3z\2\u03a8\u03ac\5\u00f5{\2"+ - "\u03a9\u03ac\5\u00f3z\2\u03aa\u03ac\t\4\2\2\u03ab\u03a8\3\2\2\2\u03ab"+ - "\u03a9\3\2\2\2\u03ab\u03aa\3\2\2\2\u03ac\u03ad\3\2\2\2\u03ad\u03ab\3\2"+ - "\2\2\u03ad\u03ae\3\2\2\2\u03ae\u00ea\3\2\2\2\u03af\u03b3\5\u00f5{\2\u03b0"+ - "\u03b3\5\u00f3z\2\u03b1\u03b3\7a\2\2\u03b2\u03af\3\2\2\2\u03b2\u03b0\3"+ - "\2\2\2\u03b2\u03b1\3\2\2\2\u03b3\u03b4\3\2\2\2\u03b4\u03b2\3\2\2\2\u03b4"+ - "\u03b5\3\2\2\2\u03b5\u00ec\3\2\2\2\u03b6\u03bc\7$\2\2\u03b7\u03bb\n\5"+ - "\2\2\u03b8\u03b9\7$\2\2\u03b9\u03bb\7$\2\2\u03ba\u03b7\3\2\2\2\u03ba\u03b8"+ - "\3\2\2\2\u03bb\u03be\3\2\2\2\u03bc\u03ba\3\2\2\2\u03bc\u03bd\3\2\2\2\u03bd"+ - "\u03bf\3\2\2\2\u03be\u03bc\3\2\2\2\u03bf\u03c0\7$\2\2\u03c0\u00ee\3\2"+ - "\2\2\u03c1\u03c7\7b\2\2\u03c2\u03c6\n\6\2\2\u03c3\u03c4\7b\2\2\u03c4\u03c6"+ - "\7b\2\2\u03c5\u03c2\3\2\2\2\u03c5\u03c3\3\2\2\2\u03c6\u03c9\3\2\2\2\u03c7"+ - "\u03c5\3\2\2\2\u03c7\u03c8\3\2\2\2\u03c8\u03ca\3\2\2\2\u03c9\u03c7\3\2"+ - "\2\2\u03ca\u03cb\7b\2\2\u03cb\u00f0\3\2\2\2\u03cc\u03ce\7G\2\2\u03cd\u03cf"+ - "\t\7\2\2\u03ce\u03cd\3\2\2\2\u03ce\u03cf\3\2\2\2\u03cf\u03d1\3\2\2\2\u03d0"+ - "\u03d2\5\u00f3z\2\u03d1\u03d0\3\2\2\2\u03d2\u03d3\3\2\2\2\u03d3\u03d1"+ - "\3\2\2\2\u03d3\u03d4\3\2\2\2\u03d4\u00f2\3\2\2\2\u03d5\u03d6\t\b\2\2\u03d6"+ - "\u00f4\3\2\2\2\u03d7\u03d8\t\t\2\2\u03d8\u00f6\3\2\2\2\u03d9\u03da\7/"+ - "\2\2\u03da\u03db\7/\2\2\u03db\u03df\3\2\2\2\u03dc\u03de\n\n\2\2\u03dd"+ - "\u03dc\3\2\2\2\u03de\u03e1\3\2\2\2\u03df\u03dd\3\2\2\2\u03df\u03e0\3\2"+ - "\2\2\u03e0\u03e3\3\2\2\2\u03e1\u03df\3\2\2\2\u03e2\u03e4\7\17\2\2\u03e3"+ - "\u03e2\3\2\2\2\u03e3\u03e4\3\2\2\2\u03e4\u03e6\3\2\2\2\u03e5\u03e7\7\f"+ - "\2\2\u03e6\u03e5\3\2\2\2\u03e6\u03e7\3\2\2\2\u03e7\u03e8\3\2\2\2\u03e8"+ - "\u03e9\b|\2\2\u03e9\u00f8\3\2\2\2\u03ea\u03eb\7\61\2\2\u03eb\u03ec\7,"+ - "\2\2\u03ec\u03f1\3\2\2\2\u03ed\u03f0\5\u00f9}\2\u03ee\u03f0\13\2\2\2\u03ef"+ - "\u03ed\3\2\2\2\u03ef\u03ee\3\2\2\2\u03f0\u03f3\3\2\2\2\u03f1\u03f2\3\2"+ - "\2\2\u03f1\u03ef\3\2\2\2\u03f2\u03f4\3\2\2\2\u03f3\u03f1\3\2\2\2\u03f4"+ - "\u03f5\7,\2\2\u03f5\u03f6\7\61\2\2\u03f6\u03f7\3\2\2\2\u03f7\u03f8\b}"+ - "\2\2\u03f8\u00fa\3\2\2\2\u03f9\u03fb\t\13\2\2\u03fa\u03f9\3\2\2\2\u03fb"+ - "\u03fc\3\2\2\2\u03fc\u03fa\3\2\2\2\u03fc\u03fd\3\2\2\2\u03fd\u03fe\3\2"+ - "\2\2\u03fe\u03ff\b~\2\2\u03ff\u00fc\3\2\2\2\u0400\u0401\13\2\2\2\u0401"+ - "\u00fe\3\2\2\2\"\2\u0342\u0363\u0365\u036d\u0372\u0378\u037f\u0384\u038a"+ - "\u038d\u0395\u0399\u039d\u03a2\u03a4\u03ab\u03ad\u03b2\u03b4\u03ba\u03bc"+ - "\u03c5\u03c7\u03ce\u03d3\u03df\u03e3\u03e6\u03ef\u03f1\u03fc\3\2\3\2"; + "w\tw\4x\tx\4y\ty\4z\tz\4{\t{\4|\t|\4}\t}\4~\t~\4\177\t\177\4\u0080\t\u0080"+ + "\3\2\3\2\3\3\3\3\3\4\3\4\3\5\3\5\3\6\3\6\3\6\3\6\3\7\3\7\3\7\3\7\3\7\3"+ + "\7\3\7\3\7\3\b\3\b\3\b\3\b\3\b\3\b\3\b\3\b\3\b\3\t\3\t\3\t\3\t\3\n\3\n"+ + "\3\n\3\n\3\13\3\13\3\13\3\f\3\f\3\f\3\f\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3"+ + "\r\3\16\3\16\3\16\3\17\3\17\3\17\3\17\3\17\3\20\3\20\3\20\3\20\3\20\3"+ + "\20\3\20\3\20\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\21\3\22\3\22\3"+ + "\22\3\22\3\22\3\22\3\22\3\22\3\23\3\23\3\23\3\23\3\23\3\23\3\23\3\23\3"+ + "\24\3\24\3\24\3\24\3\25\3\25\3\25\3\25\3\25\3\26\3\26\3\26\3\26\3\26\3"+ + "\26\3\27\3\27\3\27\3\27\3\27\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3"+ + "\30\3\31\3\31\3\31\3\31\3\31\3\31\3\31\3\31\3\31\3\32\3\32\3\32\3\32\3"+ + "\32\3\32\3\32\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3\33\3"+ + "\34\3\34\3\34\3\34\3\34\3\34\3\34\3\35\3\35\3\35\3\35\3\35\3\35\3\35\3"+ + "\35\3\36\3\36\3\36\3\36\3\36\3\36\3\36\3\36\3\37\3\37\3\37\3\37\3\37\3"+ + "\37\3 \3 \3 \3 \3 \3 \3!\3!\3!\3!\3!\3!\3!\3\"\3\"\3\"\3\"\3\"\3#\3#\3"+ + "#\3#\3#\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3%\3%\3%\3%\3%\3%\3%\3%\3%\3&\3"+ + "&\3&\3&\3&\3&\3\'\3\'\3\'\3\'\3\'\3\'\3\'\3(\3(\3(\3(\3(\3)\3)\3)\3)\3"+ + ")\3)\3*\3*\3*\3+\3+\3+\3+\3+\3+\3,\3,\3,\3,\3,\3,\3,\3,\3,\3-\3-\3-\3"+ + ".\3.\3.\3.\3.\3/\3/\3/\3/\3/\3\60\3\60\3\60\3\60\3\60\3\61\3\61\3\61\3"+ + "\61\3\61\3\62\3\62\3\62\3\62\3\62\3\62\3\63\3\63\3\63\3\63\3\63\3\63\3"+ + "\63\3\64\3\64\3\64\3\64\3\64\3\64\3\65\3\65\3\65\3\65\3\65\3\65\3\65\3"+ + "\66\3\66\3\66\3\66\3\66\3\66\3\66\3\66\3\67\3\67\3\67\3\67\3\67\3\67\3"+ + "8\38\38\38\38\38\38\39\39\39\39\39\39\39\39\3:\3:\3:\3:\3;\3;\3;\3;\3"+ + ";\3<\3<\3<\3<\3<\3<\3=\3=\3=\3>\3>\3>\3>\3>\3>\3>\3>\3>\3>\3?\3?\3?\3"+ + "@\3@\3@\3@\3@\3@\3A\3A\3A\3A\3A\3A\3B\3B\3B\3B\3B\3B\3B\3C\3C\3C\3C\3"+ + "C\3C\3C\3C\3C\3D\3D\3D\3D\3D\3E\3E\3E\3E\3E\3E\3F\3F\3F\3F\3F\3F\3G\3"+ + "G\3G\3G\3G\3G\3H\3H\3H\3H\3H\3H\3H\3H\3I\3I\3I\3I\3I\3I\3I\3J\3J\3J\3"+ + "J\3J\3J\3J\3J\3K\3K\3K\3K\3K\3K\3K\3L\3L\3L\3L\3L\3M\3M\3M\3M\3N\3N\3"+ + "N\3N\3N\3N\3O\3O\3O\3O\3O\3O\3O\3P\3P\3P\3P\3P\3Q\3Q\3Q\3Q\3Q\3R\3R\3"+ + "R\3S\3S\3S\3S\3S\3T\3T\3T\3T\3T\3T\3U\3U\3U\3U\3U\3U\3V\3V\3V\3V\3V\3"+ + "V\3V\3W\3W\3W\3W\3W\3W\3X\3X\3X\3X\3X\3Y\3Y\3Y\3Y\3Y\3Z\3Z\3Z\3Z\3Z\3"+ + "Z\3[\3[\3[\3[\3[\3[\3[\3[\3\\\3\\\3\\\3\\\3]\3]\3]\3]\3]\3]\3]\3^\3^\3"+ + "^\3_\3_\3_\3`\3`\3`\3`\3a\3a\3a\3a\3a\3a\3b\3b\3c\3c\3d\3d\3d\3d\3e\3"+ + "e\3e\3e\5e\u0346\ne\3f\3f\3g\3g\3g\3h\3h\3i\3i\3i\3j\3j\3k\3k\3l\3l\3"+ + "m\3m\3n\3n\3o\3o\3o\3p\3p\3q\3q\3r\3r\3r\3r\7r\u0367\nr\fr\16r\u036a\13"+ + "r\3r\3r\3s\6s\u036f\ns\rs\16s\u0370\3t\6t\u0374\nt\rt\16t\u0375\3t\3t"+ + "\7t\u037a\nt\ft\16t\u037d\13t\3t\3t\6t\u0381\nt\rt\16t\u0382\3t\6t\u0386"+ + "\nt\rt\16t\u0387\3t\3t\7t\u038c\nt\ft\16t\u038f\13t\5t\u0391\nt\3t\3t"+ + "\3t\3t\6t\u0397\nt\rt\16t\u0398\3t\3t\5t\u039d\nt\3u\3u\5u\u03a1\nu\3"+ + "u\3u\3u\7u\u03a6\nu\fu\16u\u03a9\13u\3v\3v\3v\3v\6v\u03af\nv\rv\16v\u03b0"+ + "\3w\3w\3w\6w\u03b6\nw\rw\16w\u03b7\3x\3x\3x\3x\7x\u03be\nx\fx\16x\u03c1"+ + "\13x\3x\3x\3y\3y\3y\3y\7y\u03c9\ny\fy\16y\u03cc\13y\3y\3y\3z\3z\5z\u03d2"+ + "\nz\3z\6z\u03d5\nz\rz\16z\u03d6\3{\3{\3|\3|\3}\3}\3}\3}\7}\u03e1\n}\f"+ + "}\16}\u03e4\13}\3}\5}\u03e7\n}\3}\5}\u03ea\n}\3}\3}\3~\3~\3~\3~\3~\7~"+ + "\u03f3\n~\f~\16~\u03f6\13~\3~\3~\3~\3~\3~\3\177\6\177\u03fe\n\177\r\177"+ + "\16\177\u03ff\3\177\3\177\3\u0080\3\u0080\3\u03f4\2\u0081\3\3\5\4\7\5"+ + "\t\6\13\7\r\b\17\t\21\n\23\13\25\f\27\r\31\16\33\17\35\20\37\21!\22#\23"+ + "%\24\'\25)\26+\27-\30/\31\61\32\63\33\65\34\67\359\36;\37= ?!A\"C#E$G"+ + "%I&K\'M(O)Q*S+U,W-Y.[/]\60_\61a\62c\63e\64g\65i\66k\67m8o9q:s;u{"+ + "?}@\177A\u0081B\u0083C\u0085D\u0087E\u0089F\u008bG\u008dH\u008fI\u0091"+ + "J\u0093K\u0095L\u0097M\u0099N\u009bO\u009dP\u009fQ\u00a1R\u00a3S\u00a5"+ + "T\u00a7U\u00a9V\u00abW\u00adX\u00afY\u00b1Z\u00b3[\u00b5\\\u00b7]\u00b9"+ + "^\u00bb_\u00bd`\u00bfa\u00c1b\u00c3c\u00c5d\u00c7e\u00c9f\u00cbg\u00cd"+ + "h\u00cfi\u00d1j\u00d3k\u00d5l\u00d7m\u00d9n\u00dbo\u00ddp\u00dfq\u00e1"+ + "r\u00e3s\u00e5t\u00e7u\u00e9v\u00ebw\u00edx\u00efy\u00f1z\u00f3\2\u00f5"+ + "\2\u00f7\2\u00f9{\u00fb|\u00fd}\u00ff~\3\2\f\3\2))\4\2BBaa\5\2<\3\2\2\2\u01b3\u01b4\7H\2\2\u01b4\u01b5\7K\2\2\u01b5"+ + "\u01b6\7T\2\2\u01b6\u01b7\7U\2\2\u01b7\u01b8\7V\2\2\u01b8@\3\2\2\2\u01b9"+ + "\u01ba\7H\2\2\u01ba\u01bb\7Q\2\2\u01bb\u01bc\7T\2\2\u01bc\u01bd\7O\2\2"+ + "\u01bd\u01be\7C\2\2\u01be\u01bf\7V\2\2\u01bfB\3\2\2\2\u01c0\u01c1\7H\2"+ + "\2\u01c1\u01c2\7T\2\2\u01c2\u01c3\7Q\2\2\u01c3\u01c4\7O\2\2\u01c4D\3\2"+ + "\2\2\u01c5\u01c6\7H\2\2\u01c6\u01c7\7W\2\2\u01c7\u01c8\7N\2\2\u01c8\u01c9"+ + "\7N\2\2\u01c9F\3\2\2\2\u01ca\u01cb\7H\2\2\u01cb\u01cc\7W\2\2\u01cc\u01cd"+ + "\7P\2\2\u01cd\u01ce\7E\2\2\u01ce\u01cf\7V\2\2\u01cf\u01d0\7K\2\2\u01d0"+ + "\u01d1\7Q\2\2\u01d1\u01d2\7P\2\2\u01d2\u01d3\7U\2\2\u01d3H\3\2\2\2\u01d4"+ + "\u01d5\7I\2\2\u01d5\u01d6\7T\2\2\u01d6\u01d7\7C\2\2\u01d7\u01d8\7R\2\2"+ + "\u01d8\u01d9\7J\2\2\u01d9\u01da\7X\2\2\u01da\u01db\7K\2\2\u01db\u01dc"+ + "\7\\\2\2\u01dcJ\3\2\2\2\u01dd\u01de\7I\2\2\u01de\u01df\7T\2\2\u01df\u01e0"+ + "\7Q\2\2\u01e0\u01e1\7W\2\2\u01e1\u01e2\7R\2\2\u01e2L\3\2\2\2\u01e3\u01e4"+ + "\7J\2\2\u01e4\u01e5\7C\2\2\u01e5\u01e6\7X\2\2\u01e6\u01e7\7K\2\2\u01e7"+ + "\u01e8\7P\2\2\u01e8\u01e9\7I\2\2\u01e9N\3\2\2\2\u01ea\u01eb\7J\2\2\u01eb"+ + "\u01ec\7Q\2\2\u01ec\u01ed\7W\2\2\u01ed\u01ee\7T\2\2\u01eeP\3\2\2\2\u01ef"+ + "\u01f0\7J\2\2\u01f0\u01f1\7Q\2\2\u01f1\u01f2\7W\2\2\u01f2\u01f3\7T\2\2"+ + "\u01f3\u01f4\7U\2\2\u01f4R\3\2\2\2\u01f5\u01f6\7K\2\2\u01f6\u01f7\7P\2"+ + "\2\u01f7T\3\2\2\2\u01f8\u01f9\7K\2\2\u01f9\u01fa\7P\2\2\u01fa\u01fb\7"+ + "P\2\2\u01fb\u01fc\7G\2\2\u01fc\u01fd\7T\2\2\u01fdV\3\2\2\2\u01fe\u01ff"+ + "\7K\2\2\u01ff\u0200\7P\2\2\u0200\u0201\7V\2\2\u0201\u0202\7G\2\2\u0202"+ + "\u0203\7T\2\2\u0203\u0204\7X\2\2\u0204\u0205\7C\2\2\u0205\u0206\7N\2\2"+ + "\u0206X\3\2\2\2\u0207\u0208\7K\2\2\u0208\u0209\7U\2\2\u0209Z\3\2\2\2\u020a"+ + "\u020b\7L\2\2\u020b\u020c\7Q\2\2\u020c\u020d\7K\2\2\u020d\u020e\7P\2\2"+ + "\u020e\\\3\2\2\2\u020f\u0210\7N\2\2\u0210\u0211\7C\2\2\u0211\u0212\7U"+ + "\2\2\u0212\u0213\7V\2\2\u0213^\3\2\2\2\u0214\u0215\7N\2\2\u0215\u0216"+ + "\7G\2\2\u0216\u0217\7H\2\2\u0217\u0218\7V\2\2\u0218`\3\2\2\2\u0219\u021a"+ + "\7N\2\2\u021a\u021b\7K\2\2\u021b\u021c\7M\2\2\u021c\u021d\7G\2\2\u021d"+ + "b\3\2\2\2\u021e\u021f\7N\2\2\u021f\u0220\7K\2\2\u0220\u0221\7O\2\2\u0221"+ + "\u0222\7K\2\2\u0222\u0223\7V\2\2\u0223d\3\2\2\2\u0224\u0225\7O\2\2\u0225"+ + "\u0226\7C\2\2\u0226\u0227\7R\2\2\u0227\u0228\7R\2\2\u0228\u0229\7G\2\2"+ + "\u0229\u022a\7F\2\2\u022af\3\2\2\2\u022b\u022c\7O\2\2\u022c\u022d\7C\2"+ + "\2\u022d\u022e\7V\2\2\u022e\u022f\7E\2\2\u022f\u0230\7J\2\2\u0230h\3\2"+ + "\2\2\u0231\u0232\7O\2\2\u0232\u0233\7K\2\2\u0233\u0234\7P\2\2\u0234\u0235"+ + "\7W\2\2\u0235\u0236\7V\2\2\u0236\u0237\7G\2\2\u0237j\3\2\2\2\u0238\u0239"+ + "\7O\2\2\u0239\u023a\7K\2\2\u023a\u023b\7P\2\2\u023b\u023c\7W\2\2\u023c"+ + "\u023d\7V\2\2\u023d\u023e\7G\2\2\u023e\u023f\7U\2\2\u023fl\3\2\2\2\u0240"+ + "\u0241\7O\2\2\u0241\u0242\7Q\2\2\u0242\u0243\7P\2\2\u0243\u0244\7V\2\2"+ + "\u0244\u0245\7J\2\2\u0245n\3\2\2\2\u0246\u0247\7O\2\2\u0247\u0248\7Q\2"+ + "\2\u0248\u0249\7P\2\2\u0249\u024a\7V\2\2\u024a\u024b\7J\2\2\u024b\u024c"+ + "\7U\2\2\u024cp\3\2\2\2\u024d\u024e\7P\2\2\u024e\u024f\7C\2\2\u024f\u0250"+ + "\7V\2\2\u0250\u0251\7W\2\2\u0251\u0252\7T\2\2\u0252\u0253\7C\2\2\u0253"+ + "\u0254\7N\2\2\u0254r\3\2\2\2\u0255\u0256\7P\2\2\u0256\u0257\7Q\2\2\u0257"+ + "\u0258\7V\2\2\u0258t\3\2\2\2\u0259\u025a\7P\2\2\u025a\u025b\7W\2\2\u025b"+ + "\u025c\7N\2\2\u025c\u025d\7N\2\2\u025dv\3\2\2\2\u025e\u025f\7P\2\2\u025f"+ + "\u0260\7W\2\2\u0260\u0261\7N\2\2\u0261\u0262\7N\2\2\u0262\u0263\7U\2\2"+ + "\u0263x\3\2\2\2\u0264\u0265\7Q\2\2\u0265\u0266\7P\2\2\u0266z\3\2\2\2\u0267"+ + "\u0268\7Q\2\2\u0268\u0269\7R\2\2\u0269\u026a\7V\2\2\u026a\u026b\7K\2\2"+ + "\u026b\u026c\7O\2\2\u026c\u026d\7K\2\2\u026d\u026e\7\\\2\2\u026e\u026f"+ + "\7G\2\2\u026f\u0270\7F\2\2\u0270|\3\2\2\2\u0271\u0272\7Q\2\2\u0272\u0273"+ + "\7T\2\2\u0273~\3\2\2\2\u0274\u0275\7Q\2\2\u0275\u0276\7T\2\2\u0276\u0277"+ + "\7F\2\2\u0277\u0278\7G\2\2\u0278\u0279\7T\2\2\u0279\u0080\3\2\2\2\u027a"+ + "\u027b\7Q\2\2\u027b\u027c\7W\2\2\u027c\u027d\7V\2\2\u027d\u027e\7G\2\2"+ + "\u027e\u027f\7T\2\2\u027f\u0082\3\2\2\2\u0280\u0281\7R\2\2\u0281\u0282"+ + "\7C\2\2\u0282\u0283\7T\2\2\u0283\u0284\7U\2\2\u0284\u0285\7G\2\2\u0285"+ + "\u0286\7F\2\2\u0286\u0084\3\2\2\2\u0287\u0288\7R\2\2\u0288\u0289\7J\2"+ + "\2\u0289\u028a\7[\2\2\u028a\u028b\7U\2\2\u028b\u028c\7K\2\2\u028c\u028d"+ + "\7E\2\2\u028d\u028e\7C\2\2\u028e\u028f\7N\2\2\u028f\u0086\3\2\2\2\u0290"+ + "\u0291\7R\2\2\u0291\u0292\7N\2\2\u0292\u0293\7C\2\2\u0293\u0294\7P\2\2"+ + "\u0294\u0088\3\2\2\2\u0295\u0296\7T\2\2\u0296\u0297\7K\2\2\u0297\u0298"+ + "\7I\2\2\u0298\u0299\7J\2\2\u0299\u029a\7V\2\2\u029a\u008a\3\2\2\2\u029b"+ + "\u029c\7T\2\2\u029c\u029d\7N\2\2\u029d\u029e\7K\2\2\u029e\u029f\7M\2\2"+ + "\u029f\u02a0\7G\2\2\u02a0\u008c\3\2\2\2\u02a1\u02a2\7S\2\2\u02a2\u02a3"+ + "\7W\2\2\u02a3\u02a4\7G\2\2\u02a4\u02a5\7T\2\2\u02a5\u02a6\7[\2\2\u02a6"+ + "\u008e\3\2\2\2\u02a7\u02a8\7U\2\2\u02a8\u02a9\7E\2\2\u02a9\u02aa\7J\2"+ + "\2\u02aa\u02ab\7G\2\2\u02ab\u02ac\7O\2\2\u02ac\u02ad\7C\2\2\u02ad\u02ae"+ + "\7U\2\2\u02ae\u0090\3\2\2\2\u02af\u02b0\7U\2\2\u02b0\u02b1\7G\2\2\u02b1"+ + "\u02b2\7E\2\2\u02b2\u02b3\7Q\2\2\u02b3\u02b4\7P\2\2\u02b4\u02b5\7F\2\2"+ + "\u02b5\u0092\3\2\2\2\u02b6\u02b7\7U\2\2\u02b7\u02b8\7G\2\2\u02b8\u02b9"+ + "\7E\2\2\u02b9\u02ba\7Q\2\2\u02ba\u02bb\7P\2\2\u02bb\u02bc\7F\2\2\u02bc"+ + "\u02bd\7U\2\2\u02bd\u0094\3\2\2\2\u02be\u02bf\7U\2\2\u02bf\u02c0\7G\2"+ + "\2\u02c0\u02c1\7N\2\2\u02c1\u02c2\7G\2\2\u02c2\u02c3\7E\2\2\u02c3\u02c4"+ + "\7V\2\2\u02c4\u0096\3\2\2\2\u02c5\u02c6\7U\2\2\u02c6\u02c7\7J\2\2\u02c7"+ + "\u02c8\7Q\2\2\u02c8\u02c9\7Y\2\2\u02c9\u0098\3\2\2\2\u02ca\u02cb\7U\2"+ + "\2\u02cb\u02cc\7[\2\2\u02cc\u02cd\7U\2\2\u02cd\u009a\3\2\2\2\u02ce\u02cf"+ + "\7V\2\2\u02cf\u02d0\7C\2\2\u02d0\u02d1\7D\2\2\u02d1\u02d2\7N\2\2\u02d2"+ + "\u02d3\7G\2\2\u02d3\u009c\3\2\2\2\u02d4\u02d5\7V\2\2\u02d5\u02d6\7C\2"+ + "\2\u02d6\u02d7\7D\2\2\u02d7\u02d8\7N\2\2\u02d8\u02d9\7G\2\2\u02d9\u02da"+ + "\7U\2\2\u02da\u009e\3\2\2\2\u02db\u02dc\7V\2\2\u02dc\u02dd\7G\2\2\u02dd"+ + "\u02de\7Z\2\2\u02de\u02df\7V\2\2\u02df\u00a0\3\2\2\2\u02e0\u02e1\7V\2"+ + "\2\u02e1\u02e2\7T\2\2\u02e2\u02e3\7W\2\2\u02e3\u02e4\7G\2\2\u02e4\u00a2"+ + "\3\2\2\2\u02e5\u02e6\7V\2\2\u02e6\u02e7\7Q\2\2\u02e7\u00a4\3\2\2\2\u02e8"+ + "\u02e9\7V\2\2\u02e9\u02ea\7[\2\2\u02ea\u02eb\7R\2\2\u02eb\u02ec\7G\2\2"+ + "\u02ec\u00a6\3\2\2\2\u02ed\u02ee\7V\2\2\u02ee\u02ef\7[\2\2\u02ef\u02f0"+ + "\7R\2\2\u02f0\u02f1\7G\2\2\u02f1\u02f2\7U\2\2\u02f2\u00a8\3\2\2\2\u02f3"+ + "\u02f4\7W\2\2\u02f4\u02f5\7U\2\2\u02f5\u02f6\7K\2\2\u02f6\u02f7\7P\2\2"+ + "\u02f7\u02f8\7I\2\2\u02f8\u00aa\3\2\2\2\u02f9\u02fa\7X\2\2\u02fa\u02fb"+ + "\7G\2\2\u02fb\u02fc\7T\2\2\u02fc\u02fd\7K\2\2\u02fd\u02fe\7H\2\2\u02fe"+ + "\u02ff\7[\2\2\u02ff\u00ac\3\2\2\2\u0300\u0301\7Y\2\2\u0301\u0302\7J\2"+ + "\2\u0302\u0303\7G\2\2\u0303\u0304\7T\2\2\u0304\u0305\7G\2\2\u0305\u00ae"+ + "\3\2\2\2\u0306\u0307\7Y\2\2\u0307\u0308\7K\2\2\u0308\u0309\7V\2\2\u0309"+ + "\u030a\7J\2\2\u030a\u00b0\3\2\2\2\u030b\u030c\7[\2\2\u030c\u030d\7G\2"+ + "\2\u030d\u030e\7C\2\2\u030e\u030f\7T\2\2\u030f\u00b2\3\2\2\2\u0310\u0311"+ + "\7[\2\2\u0311\u0312\7G\2\2\u0312\u0313\7C\2\2\u0313\u0314\7T\2\2\u0314"+ + "\u0315\7U\2\2\u0315\u00b4\3\2\2\2\u0316\u0317\7}\2\2\u0317\u0318\7G\2"+ + "\2\u0318\u0319\7U\2\2\u0319\u031a\7E\2\2\u031a\u031b\7C\2\2\u031b\u031c"+ + "\7R\2\2\u031c\u031d\7G\2\2\u031d\u00b6\3\2\2\2\u031e\u031f\7}\2\2\u031f"+ + "\u0320\7H\2\2\u0320\u0321\7P\2\2\u0321\u00b8\3\2\2\2\u0322\u0323\7}\2"+ + "\2\u0323\u0324\7N\2\2\u0324\u0325\7K\2\2\u0325\u0326\7O\2\2\u0326\u0327"+ + "\7K\2\2\u0327\u0328\7V\2\2\u0328\u00ba\3\2\2\2\u0329\u032a\7}\2\2\u032a"+ + "\u032b\7F\2\2\u032b\u00bc\3\2\2\2\u032c\u032d\7}\2\2\u032d\u032e\7V\2"+ + "\2\u032e\u00be\3\2\2\2\u032f\u0330\7}\2\2\u0330\u0331\7V\2\2\u0331\u0332"+ + "\7U\2\2\u0332\u00c0\3\2\2\2\u0333\u0334\7}\2\2\u0334\u0335\7I\2\2\u0335"+ + "\u0336\7W\2\2\u0336\u0337\7K\2\2\u0337\u0338\7F\2\2\u0338\u00c2\3\2\2"+ + "\2\u0339\u033a\7\177\2\2\u033a\u00c4\3\2\2\2\u033b\u033c\7?\2\2\u033c"+ + "\u00c6\3\2\2\2\u033d\u033e\7>\2\2\u033e\u033f\7?\2\2\u033f\u0340\7@\2"+ + "\2\u0340\u00c8\3\2\2\2\u0341\u0342\7>\2\2\u0342\u0346\7@\2\2\u0343\u0344"+ + "\7#\2\2\u0344\u0346\7?\2\2\u0345\u0341\3\2\2\2\u0345\u0343\3\2\2\2\u0346"+ + "\u00ca\3\2\2\2\u0347\u0348\7>\2\2\u0348\u00cc\3\2\2\2\u0349\u034a\7>\2"+ + "\2\u034a\u034b\7?\2\2\u034b\u00ce\3\2\2\2\u034c\u034d\7@\2\2\u034d\u00d0"+ + "\3\2\2\2\u034e\u034f\7@\2\2\u034f\u0350\7?\2\2\u0350\u00d2\3\2\2\2\u0351"+ + "\u0352\7-\2\2\u0352\u00d4\3\2\2\2\u0353\u0354\7/\2\2\u0354\u00d6\3\2\2"+ + "\2\u0355\u0356\7,\2\2\u0356\u00d8\3\2\2\2\u0357\u0358\7\61\2\2\u0358\u00da"+ + "\3\2\2\2\u0359\u035a\7\'\2\2\u035a\u00dc\3\2\2\2\u035b\u035c\7~\2\2\u035c"+ + "\u035d\7~\2\2\u035d\u00de\3\2\2\2\u035e\u035f\7\60\2\2\u035f\u00e0\3\2"+ + "\2\2\u0360\u0361\7A\2\2\u0361\u00e2\3\2\2\2\u0362\u0368\7)\2\2\u0363\u0367"+ + "\n\2\2\2\u0364\u0365\7)\2\2\u0365\u0367\7)\2\2\u0366\u0363\3\2\2\2\u0366"+ + "\u0364\3\2\2\2\u0367\u036a\3\2\2\2\u0368\u0366\3\2\2\2\u0368\u0369\3\2"+ + "\2\2\u0369\u036b\3\2\2\2\u036a\u0368\3\2\2\2\u036b\u036c\7)\2\2\u036c"+ + "\u00e4\3\2\2\2\u036d\u036f\5\u00f5{\2\u036e\u036d\3\2\2\2\u036f\u0370"+ + "\3\2\2\2\u0370\u036e\3\2\2\2\u0370\u0371\3\2\2\2\u0371\u00e6\3\2\2\2\u0372"+ + "\u0374\5\u00f5{\2\u0373\u0372\3\2\2\2\u0374\u0375\3\2\2\2\u0375\u0373"+ + "\3\2\2\2\u0375\u0376\3\2\2\2\u0376\u0377\3\2\2\2\u0377\u037b\5\u00dfp"+ + "\2\u0378\u037a\5\u00f5{\2\u0379\u0378\3\2\2\2\u037a\u037d\3\2\2\2\u037b"+ + "\u0379\3\2\2\2\u037b\u037c\3\2\2\2\u037c\u039d\3\2\2\2\u037d\u037b\3\2"+ + "\2\2\u037e\u0380\5\u00dfp\2\u037f\u0381\5\u00f5{\2\u0380\u037f\3\2\2\2"+ + "\u0381\u0382\3\2\2\2\u0382\u0380\3\2\2\2\u0382\u0383\3\2\2\2\u0383\u039d"+ + "\3\2\2\2\u0384\u0386\5\u00f5{\2\u0385\u0384\3\2\2\2\u0386\u0387\3\2\2"+ + "\2\u0387\u0385\3\2\2\2\u0387\u0388\3\2\2\2\u0388\u0390\3\2\2\2\u0389\u038d"+ + "\5\u00dfp\2\u038a\u038c\5\u00f5{\2\u038b\u038a\3\2\2\2\u038c\u038f\3\2"+ + "\2\2\u038d\u038b\3\2\2\2\u038d\u038e\3\2\2\2\u038e\u0391\3\2\2\2\u038f"+ + "\u038d\3\2\2\2\u0390\u0389\3\2\2\2\u0390\u0391\3\2\2\2\u0391\u0392\3\2"+ + "\2\2\u0392\u0393\5\u00f3z\2\u0393\u039d\3\2\2\2\u0394\u0396\5\u00dfp\2"+ + "\u0395\u0397\5\u00f5{\2\u0396\u0395\3\2\2\2\u0397\u0398\3\2\2\2\u0398"+ + "\u0396\3\2\2\2\u0398\u0399\3\2\2\2\u0399\u039a\3\2\2\2\u039a\u039b\5\u00f3"+ + "z\2\u039b\u039d\3\2\2\2\u039c\u0373\3\2\2\2\u039c\u037e\3\2\2\2\u039c"+ + "\u0385\3\2\2\2\u039c\u0394\3\2\2\2\u039d\u00e8\3\2\2\2\u039e\u03a1\5\u00f7"+ + "|\2\u039f\u03a1\7a\2\2\u03a0\u039e\3\2\2\2\u03a0\u039f\3\2\2\2\u03a1\u03a7"+ + "\3\2\2\2\u03a2\u03a6\5\u00f7|\2\u03a3\u03a6\5\u00f5{\2\u03a4\u03a6\t\3"+ + "\2\2\u03a5\u03a2\3\2\2\2\u03a5\u03a3\3\2\2\2\u03a5\u03a4\3\2\2\2\u03a6"+ + "\u03a9\3\2\2\2\u03a7\u03a5\3\2\2\2\u03a7\u03a8\3\2\2\2\u03a8\u00ea\3\2"+ + "\2\2\u03a9\u03a7\3\2\2\2\u03aa\u03ae\5\u00f5{\2\u03ab\u03af\5\u00f7|\2"+ + "\u03ac\u03af\5\u00f5{\2\u03ad\u03af\t\4\2\2\u03ae\u03ab\3\2\2\2\u03ae"+ + "\u03ac\3\2\2\2\u03ae\u03ad\3\2\2\2\u03af\u03b0\3\2\2\2\u03b0\u03ae\3\2"+ + "\2\2\u03b0\u03b1\3\2\2\2\u03b1\u00ec\3\2\2\2\u03b2\u03b6\5\u00f7|\2\u03b3"+ + "\u03b6\5\u00f5{\2\u03b4\u03b6\7a\2\2\u03b5\u03b2\3\2\2\2\u03b5\u03b3\3"+ + "\2\2\2\u03b5\u03b4\3\2\2\2\u03b6\u03b7\3\2\2\2\u03b7\u03b5\3\2\2\2\u03b7"+ + "\u03b8\3\2\2\2\u03b8\u00ee\3\2\2\2\u03b9\u03bf\7$\2\2\u03ba\u03be\n\5"+ + "\2\2\u03bb\u03bc\7$\2\2\u03bc\u03be\7$\2\2\u03bd\u03ba\3\2\2\2\u03bd\u03bb"+ + "\3\2\2\2\u03be\u03c1\3\2\2\2\u03bf\u03bd\3\2\2\2\u03bf\u03c0\3\2\2\2\u03c0"+ + "\u03c2\3\2\2\2\u03c1\u03bf\3\2\2\2\u03c2\u03c3\7$\2\2\u03c3\u00f0\3\2"+ + "\2\2\u03c4\u03ca\7b\2\2\u03c5\u03c9\n\6\2\2\u03c6\u03c7\7b\2\2\u03c7\u03c9"+ + "\7b\2\2\u03c8\u03c5\3\2\2\2\u03c8\u03c6\3\2\2\2\u03c9\u03cc\3\2\2\2\u03ca"+ + "\u03c8\3\2\2\2\u03ca\u03cb\3\2\2\2\u03cb\u03cd\3\2\2\2\u03cc\u03ca\3\2"+ + "\2\2\u03cd\u03ce\7b\2\2\u03ce\u00f2\3\2\2\2\u03cf\u03d1\7G\2\2\u03d0\u03d2"+ + "\t\7\2\2\u03d1\u03d0\3\2\2\2\u03d1\u03d2\3\2\2\2\u03d2\u03d4\3\2\2\2\u03d3"+ + "\u03d5\5\u00f5{\2\u03d4\u03d3\3\2\2\2\u03d5\u03d6\3\2\2\2\u03d6\u03d4"+ + "\3\2\2\2\u03d6\u03d7\3\2\2\2\u03d7\u00f4\3\2\2\2\u03d8\u03d9\t\b\2\2\u03d9"+ + "\u00f6\3\2\2\2\u03da\u03db\t\t\2\2\u03db\u00f8\3\2\2\2\u03dc\u03dd\7/"+ + "\2\2\u03dd\u03de\7/\2\2\u03de\u03e2\3\2\2\2\u03df\u03e1\n\n\2\2\u03e0"+ + "\u03df\3\2\2\2\u03e1\u03e4\3\2\2\2\u03e2\u03e0\3\2\2\2\u03e2\u03e3\3\2"+ + "\2\2\u03e3\u03e6\3\2\2\2\u03e4\u03e2\3\2\2\2\u03e5\u03e7\7\17\2\2\u03e6"+ + "\u03e5\3\2\2\2\u03e6\u03e7\3\2\2\2\u03e7\u03e9\3\2\2\2\u03e8\u03ea\7\f"+ + "\2\2\u03e9\u03e8\3\2\2\2\u03e9\u03ea\3\2\2\2\u03ea\u03eb\3\2\2\2\u03eb"+ + "\u03ec\b}\2\2\u03ec\u00fa\3\2\2\2\u03ed\u03ee\7\61\2\2\u03ee\u03ef\7,"+ + "\2\2\u03ef\u03f4\3\2\2\2\u03f0\u03f3\5\u00fb~\2\u03f1\u03f3\13\2\2\2\u03f2"+ + "\u03f0\3\2\2\2\u03f2\u03f1\3\2\2\2\u03f3\u03f6\3\2\2\2\u03f4\u03f5\3\2"+ + "\2\2\u03f4\u03f2\3\2\2\2\u03f5\u03f7\3\2\2\2\u03f6\u03f4\3\2\2\2\u03f7"+ + "\u03f8\7,\2\2\u03f8\u03f9\7\61\2\2\u03f9\u03fa\3\2\2\2\u03fa\u03fb\b~"+ + "\2\2\u03fb\u00fc\3\2\2\2\u03fc\u03fe\t\13\2\2\u03fd\u03fc\3\2\2\2\u03fe"+ + "\u03ff\3\2\2\2\u03ff\u03fd\3\2\2\2\u03ff\u0400\3\2\2\2\u0400\u0401\3\2"+ + "\2\2\u0401\u0402\b\177\2\2\u0402\u00fe\3\2\2\2\u0403\u0404\13\2\2\2\u0404"+ + "\u0100\3\2\2\2\"\2\u0345\u0366\u0368\u0370\u0375\u037b\u0382\u0387\u038d"+ + "\u0390\u0398\u039c\u03a0\u03a5\u03a7\u03ae\u03b0\u03b5\u03b7\u03bd\u03bf"+ + "\u03c8\u03ca\u03d1\u03d6\u03e2\u03e6\u03e9\u03f2\u03f4\u03ff\3\2\3\2"; public static final ATN _ATN = new ATNDeserializer().deserialize(_serializedATN.toCharArray()); static { diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseParser.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseParser.java index 1635baffc7b..0239a8609b7 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseParser.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/parser/SqlBaseParser.java @@ -30,12 +30,12 @@ class SqlBaseParser extends Parser { SYS=76, TABLE=77, TABLES=78, TEXT=79, TRUE=80, TO=81, TYPE=82, TYPES=83, USING=84, VERIFY=85, WHERE=86, WITH=87, YEAR=88, YEARS=89, ESCAPE_ESC=90, FUNCTION_ESC=91, LIMIT_ESC=92, DATE_ESC=93, TIME_ESC=94, TIMESTAMP_ESC=95, - GUID_ESC=96, ESC_END=97, EQ=98, NEQ=99, LT=100, LTE=101, GT=102, GTE=103, - PLUS=104, MINUS=105, ASTERISK=106, SLASH=107, PERCENT=108, CONCAT=109, - DOT=110, PARAM=111, STRING=112, INTEGER_VALUE=113, DECIMAL_VALUE=114, - IDENTIFIER=115, DIGIT_IDENTIFIER=116, TABLE_IDENTIFIER=117, QUOTED_IDENTIFIER=118, - BACKQUOTED_IDENTIFIER=119, SIMPLE_COMMENT=120, BRACKETED_COMMENT=121, - WS=122, UNRECOGNIZED=123, DELIMITER=124; + GUID_ESC=96, ESC_END=97, EQ=98, NULLEQ=99, NEQ=100, LT=101, LTE=102, GT=103, + GTE=104, PLUS=105, MINUS=106, ASTERISK=107, SLASH=108, PERCENT=109, CONCAT=110, + DOT=111, PARAM=112, STRING=113, INTEGER_VALUE=114, DECIMAL_VALUE=115, + IDENTIFIER=116, DIGIT_IDENTIFIER=117, TABLE_IDENTIFIER=118, QUOTED_IDENTIFIER=119, + BACKQUOTED_IDENTIFIER=120, SIMPLE_COMMENT=121, BRACKETED_COMMENT=122, + WS=123, UNRECOGNIZED=124, DELIMITER=125; public static final int RULE_singleStatement = 0, RULE_singleExpression = 1, RULE_statement = 2, RULE_query = 3, RULE_queryNoWith = 4, RULE_limitClause = 5, RULE_queryTerm = 6, @@ -83,8 +83,8 @@ class SqlBaseParser extends Parser { "'SELECT'", "'SHOW'", "'SYS'", "'TABLE'", "'TABLES'", "'TEXT'", "'TRUE'", "'TO'", "'TYPE'", "'TYPES'", "'USING'", "'VERIFY'", "'WHERE'", "'WITH'", "'YEAR'", "'YEARS'", "'{ESCAPE'", "'{FN'", "'{LIMIT'", "'{D'", "'{T'", - "'{TS'", "'{GUID'", "'}'", "'='", null, "'<'", "'<='", "'>'", "'>='", - "'+'", "'-'", "'*'", "'/'", "'%'", "'||'", "'.'", "'?'" + "'{TS'", "'{GUID'", "'}'", "'='", "'<=>'", null, "'<'", "'<='", "'>'", + "'>='", "'+'", "'-'", "'*'", "'/'", "'%'", "'||'", "'.'", "'?'" }; private static final String[] _SYMBOLIC_NAMES = { null, null, null, null, null, "ALL", "ANALYZE", "ANALYZED", "AND", "ANY", @@ -99,11 +99,11 @@ class SqlBaseParser extends Parser { "SELECT", "SHOW", "SYS", "TABLE", "TABLES", "TEXT", "TRUE", "TO", "TYPE", "TYPES", "USING", "VERIFY", "WHERE", "WITH", "YEAR", "YEARS", "ESCAPE_ESC", "FUNCTION_ESC", "LIMIT_ESC", "DATE_ESC", "TIME_ESC", "TIMESTAMP_ESC", - "GUID_ESC", "ESC_END", "EQ", "NEQ", "LT", "LTE", "GT", "GTE", "PLUS", - "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", "STRING", - "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", "TABLE_IDENTIFIER", - "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "SIMPLE_COMMENT", "BRACKETED_COMMENT", - "WS", "UNRECOGNIZED", "DELIMITER" + "GUID_ESC", "ESC_END", "EQ", "NULLEQ", "NEQ", "LT", "LTE", "GT", "GTE", + "PLUS", "MINUS", "ASTERISK", "SLASH", "PERCENT", "CONCAT", "DOT", "PARAM", + "STRING", "INTEGER_VALUE", "DECIMAL_VALUE", "IDENTIFIER", "DIGIT_IDENTIFIER", + "TABLE_IDENTIFIER", "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER", "SIMPLE_COMMENT", + "BRACKETED_COMMENT", "WS", "UNRECOGNIZED", "DELIMITER" }; public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES); @@ -1196,7 +1196,7 @@ class SqlBaseParser extends Parser { match(TYPES); setState(213); _la = _input.LA(1); - if (((((_la - 104)) & ~0x3f) == 0 && ((1L << (_la - 104)) & ((1L << (PLUS - 104)) | (1L << (MINUS - 104)) | (1L << (INTEGER_VALUE - 104)) | (1L << (DECIMAL_VALUE - 104)))) != 0)) { + if (((((_la - 105)) & ~0x3f) == 0 && ((1L << (_la - 105)) & ((1L << (PLUS - 105)) | (1L << (MINUS - 105)) | (1L << (INTEGER_VALUE - 105)) | (1L << (DECIMAL_VALUE - 105)))) != 0)) { { setState(210); _la = _input.LA(1); @@ -3963,7 +3963,7 @@ class SqlBaseParser extends Parser { setState(558); ((ArithmeticBinaryContext)_localctx).operator = _input.LT(1); _la = _input.LA(1); - if ( !(((((_la - 106)) & ~0x3f) == 0 && ((1L << (_la - 106)) & ((1L << (ASTERISK - 106)) | (1L << (SLASH - 106)) | (1L << (PERCENT - 106)))) != 0)) ) { + if ( !(((((_la - 107)) & ~0x3f) == 0 && ((1L << (_la - 107)) & ((1L << (ASTERISK - 107)) | (1L << (SLASH - 107)) | (1L << (PERCENT - 107)))) != 0)) ) { ((ArithmeticBinaryContext)_localctx).operator = (Token)_errHandler.recoverInline(this); } else { consume(); @@ -5266,6 +5266,7 @@ class SqlBaseParser extends Parser { public static class ComparisonOperatorContext extends ParserRuleContext { public TerminalNode EQ() { return getToken(SqlBaseParser.EQ, 0); } + public TerminalNode NULLEQ() { return getToken(SqlBaseParser.NULLEQ, 0); } public TerminalNode NEQ() { return getToken(SqlBaseParser.NEQ, 0); } public TerminalNode LT() { return getToken(SqlBaseParser.LT, 0); } public TerminalNode LTE() { return getToken(SqlBaseParser.LTE, 0); } @@ -5299,7 +5300,7 @@ class SqlBaseParser extends Parser { { setState(690); _la = _input.LA(1); - if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (EQ - 98)) | (1L << (NEQ - 98)) | (1L << (LT - 98)) | (1L << (LTE - 98)) | (1L << (GT - 98)) | (1L << (GTE - 98)))) != 0)) ) { + if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (EQ - 98)) | (1L << (NULLEQ - 98)) | (1L << (NEQ - 98)) | (1L << (LT - 98)) | (1L << (LTE - 98)) | (1L << (GT - 98)) | (1L << (GTE - 98)))) != 0)) ) { _errHandler.recoverInline(this); } else { consume(); @@ -6300,9 +6301,9 @@ class SqlBaseParser extends Parser { } public static final String _serializedATN = - "\3\u0430\ud6d1\u8206\uad2d\u4417\uaef1\u8d80\uaadd\3~\u02f7\4\2\t\2\4"+ - "\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13\t"+ - "\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22"+ + "\3\u0430\ud6d1\u8206\uad2d\u4417\uaef1\u8d80\uaadd\3\177\u02f7\4\2\t\2"+ + "\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13"+ + "\t\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22"+ "\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27\4\30\t\30\4\31\t\31"+ "\4\32\t\32\4\33\t\33\4\34\t\34\4\35\t\35\4\36\t\36\4\37\t\37\4 \t \4!"+ "\t!\4\"\t\"\4#\t#\4$\t$\4%\t%\4&\t&\4\'\t\'\4(\t(\4)\t)\4*\t*\4+\t+\4"+ @@ -6359,8 +6360,8 @@ class SqlBaseParser extends Parser { "\3\63\5\63\u02ed\n\63\3\64\3\64\5\64\u02f1\n\64\3\65\3\65\3\66\3\66\3"+ "\66\2\4.<\67\2\4\6\b\n\f\16\20\22\24\26\30\32\34\36 \"$&(*,.\60\62\64"+ "\668:<>@BDFHJLNPRTVXZ\\^`bdfhj\2\22\b\2\7\7\t\t\34\34\64\64??CC\4\2&&"+ - "QQ\4\2\t\t??\4\2##++\3\2\30\31\3\2jk\4\2\7\7ss\4\2\r\r\30\30\4\2!!\60"+ - "\60\4\2\7\7\32\32\3\2ln\3\2di\4\2 RR\7\2\25\26)*\669JKZ[\3\2qr\30\2\b"+ + "QQ\4\2\t\t??\4\2##++\3\2\30\31\3\2kl\4\2\7\7tt\4\2\r\r\30\30\4\2!!\60"+ + "\60\4\2\7\7\32\32\3\2mo\3\2dj\4\2 RR\7\2\25\26)*\669JKZ[\3\2rs\30\2\b"+ "\t\22\23\25\25\27\27\34\34\36\36!\"%&))--\60\60\63\64\66\6688??CEGJMN"+ "PQTUWWZZ\u0352\2l\3\2\2\2\4o\3\2\2\2\6\u00dc\3\2\2\2\b\u00e7\3\2\2\2\n"+ "\u00eb\3\2\2\2\f\u0100\3\2\2\2\16\u0107\3\2\2\2\20\u0109\3\2\2\2\22\u0111"+ @@ -6531,9 +6532,9 @@ class SqlBaseParser extends Parser { "\4\u0238\u023a\3\2\2\2\u0239\u022f\3\2\2\2\u0239\u0232\3\2\2\2\u0239\u0235"+ "\3\2\2\2\u023a\u023d\3\2\2\2\u023b\u0239\3\2\2\2\u023b\u023c\3\2\2\2\u023c"+ "=\3\2\2\2\u023d\u023b\3\2\2\2\u023e\u0252\5@!\2\u023f\u0252\5F$\2\u0240"+ - "\u0252\5P)\2\u0241\u0242\5\\/\2\u0242\u0243\7p\2\2\u0243\u0245\3\2\2\2"+ + "\u0252\5P)\2\u0241\u0242\5\\/\2\u0242\u0243\7q\2\2\u0243\u0245\3\2\2\2"+ "\u0244\u0241\3\2\2\2\u0244\u0245\3\2\2\2\u0245\u0246\3\2\2\2\u0246\u0252"+ - "\7l\2\2\u0247\u0252\5J&\2\u0248\u0249\7\3\2\2\u0249\u024a\5\b\5\2\u024a"+ + "\7m\2\2\u0247\u0252\5J&\2\u0248\u0249\7\3\2\2\u0249\u024a\5\b\5\2\u024a"+ "\u024b\7\4\2\2\u024b\u0252\3\2\2\2\u024c\u0252\5\\/\2\u024d\u024e\7\3"+ "\2\2\u024e\u024f\5,\27\2\u024f\u0250\7\4\2\2\u0250\u0252\3\2\2\2\u0251"+ "\u023e\3\2\2\2\u0251\u023f\3\2\2\2\u0251\u0240\3\2\2\2\u0251\u0244\3\2"+ @@ -6561,8 +6562,8 @@ class SqlBaseParser extends Parser { "\u0293\u0297\7\61\2\2\u0294\u0297\7F\2\2\u0295\u0297\5^\60\2\u0296\u0293"+ "\3\2\2\2\u0296\u0294\3\2\2\2\u0296\u0295\3\2\2\2\u0297O\3\2\2\2\u0298"+ "\u02b3\7<\2\2\u0299\u02b3\5V,\2\u029a\u02b3\5f\64\2\u029b\u02b3\5T+\2"+ - "\u029c\u029e\7r\2\2\u029d\u029c\3\2\2\2\u029e\u029f\3\2\2\2\u029f\u029d"+ - "\3\2\2\2\u029f\u02a0\3\2\2\2\u02a0\u02b3\3\2\2\2\u02a1\u02b3\7q\2\2\u02a2"+ + "\u029c\u029e\7s\2\2\u029d\u029c\3\2\2\2\u029e\u029f\3\2\2\2\u029f\u029d"+ + "\3\2\2\2\u029f\u02a0\3\2\2\2\u02a0\u02b3\3\2\2\2\u02a1\u02b3\7r\2\2\u02a2"+ "\u02a3\7_\2\2\u02a3\u02a4\5h\65\2\u02a4\u02a5\7c\2\2\u02a5\u02b3\3\2\2"+ "\2\u02a6\u02a7\7`\2\2\u02a7\u02a8\5h\65\2\u02a8\u02a9\7c\2\2\u02a9\u02b3"+ "\3\2\2\2\u02aa\u02ab\7a\2\2\u02ab\u02ac\5h\65\2\u02ac\u02ad\7c\2\2\u02ad"+ @@ -6577,19 +6578,19 @@ class SqlBaseParser extends Parser { "\2\2\u02c0\u02c3\5X-\2\u02c1\u02c2\7S\2\2\u02c2\u02c4\5X-\2\u02c3\u02c1"+ "\3\2\2\2\u02c3\u02c4\3\2\2\2\u02c4W\3\2\2\2\u02c5\u02c6\t\17\2\2\u02c6"+ "Y\3\2\2\2\u02c7\u02c8\5^\60\2\u02c8[\3\2\2\2\u02c9\u02ca\5^\60\2\u02ca"+ - "\u02cb\7p\2\2\u02cb\u02cd\3\2\2\2\u02cc\u02c9\3\2\2\2\u02cd\u02d0\3\2"+ + "\u02cb\7q\2\2\u02cb\u02cd\3\2\2\2\u02cc\u02c9\3\2\2\2\u02cd\u02d0\3\2"+ "\2\2\u02ce\u02cc\3\2\2\2\u02ce\u02cf\3\2\2\2\u02cf\u02d1\3\2\2\2\u02d0"+ "\u02ce\3\2\2\2\u02d1\u02d2\5^\60\2\u02d2]\3\2\2\2\u02d3\u02d6\5b\62\2"+ "\u02d4\u02d6\5d\63\2\u02d5\u02d3\3\2\2\2\u02d5\u02d4\3\2\2\2\u02d6_\3"+ "\2\2\2\u02d7\u02d8\5^\60\2\u02d8\u02d9\7\6\2\2\u02d9\u02db\3\2\2\2\u02da"+ - "\u02d7\3\2\2\2\u02da\u02db\3\2\2\2\u02db\u02dc\3\2\2\2\u02dc\u02e4\7w"+ + "\u02d7\3\2\2\2\u02da\u02db\3\2\2\2\u02db\u02dc\3\2\2\2\u02dc\u02e4\7x"+ "\2\2\u02dd\u02de\5^\60\2\u02de\u02df\7\6\2\2\u02df\u02e1\3\2\2\2\u02e0"+ "\u02dd\3\2\2\2\u02e0\u02e1\3\2\2\2\u02e1\u02e2\3\2\2\2\u02e2\u02e4\5^"+ "\60\2\u02e3\u02da\3\2\2\2\u02e3\u02e0\3\2\2\2\u02e4a\3\2\2\2\u02e5\u02e8"+ - "\7x\2\2\u02e6\u02e8\7y\2\2\u02e7\u02e5\3\2\2\2\u02e7\u02e6\3\2\2\2\u02e8"+ - "c\3\2\2\2\u02e9\u02ed\7u\2\2\u02ea\u02ed\5j\66\2\u02eb\u02ed\7v\2\2\u02ec"+ + "\7y\2\2\u02e6\u02e8\7z\2\2\u02e7\u02e5\3\2\2\2\u02e7\u02e6\3\2\2\2\u02e8"+ + "c\3\2\2\2\u02e9\u02ed\7v\2\2\u02ea\u02ed\5j\66\2\u02eb\u02ed\7w\2\2\u02ec"+ "\u02e9\3\2\2\2\u02ec\u02ea\3\2\2\2\u02ec\u02eb\3\2\2\2\u02ede\3\2\2\2"+ - "\u02ee\u02f1\7t\2\2\u02ef\u02f1\7s\2\2\u02f0\u02ee\3\2\2\2\u02f0\u02ef"+ + "\u02ee\u02f1\7u\2\2\u02ef\u02f1\7t\2\2\u02f0\u02ee\3\2\2\2\u02f0\u02ef"+ "\3\2\2\2\u02f1g\3\2\2\2\u02f2\u02f3\t\20\2\2\u02f3i\3\2\2\2\u02f4\u02f5"+ "\t\21\2\2\u02f5k\3\2\2\2f{}\u0081\u008a\u008c\u0090\u0097\u009e\u00a3"+ "\u00a8\u00b2\u00b6\u00be\u00c1\u00c7\u00cc\u00cf\u00d4\u00d7\u00dc\u00e4"+ diff --git a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/planner/QueryTranslator.java b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/planner/QueryTranslator.java index 2713a01816c..2c1f5a1e449 100644 --- a/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/planner/QueryTranslator.java +++ b/x-pack/plugin/sql/src/main/java/org/elasticsearch/xpack/sql/planner/QueryTranslator.java @@ -47,6 +47,7 @@ import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.In; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThan; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThanOrEqual; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NotEquals; +import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NullEquals; import org.elasticsearch.xpack.sql.expression.predicate.regex.Like; import org.elasticsearch.xpack.sql.expression.predicate.regex.LikePattern; import org.elasticsearch.xpack.sql.expression.predicate.regex.RLike; @@ -585,7 +586,7 @@ final class QueryTranslator { if (bc instanceof LessThanOrEqual) { return new RangeQuery(loc, name, null, false, value, true, format); } - if (bc instanceof Equals || bc instanceof NotEquals) { + if (bc instanceof Equals || bc instanceof NullEquals || bc instanceof NotEquals) { if (bc.left() instanceof FieldAttribute) { FieldAttribute fa = (FieldAttribute) bc.left(); // equality should always be against an exact match diff --git a/x-pack/plugin/sql/src/main/resources/org/elasticsearch/xpack/sql/plugin/sql_whitelist.txt b/x-pack/plugin/sql/src/main/resources/org/elasticsearch/xpack/sql/plugin/sql_whitelist.txt index f6c49943f36..4689d95e8b9 100644 --- a/x-pack/plugin/sql/src/main/resources/org/elasticsearch/xpack/sql/plugin/sql_whitelist.txt +++ b/x-pack/plugin/sql/src/main/resources/org/elasticsearch/xpack/sql/plugin/sql_whitelist.txt @@ -26,6 +26,7 @@ class org.elasticsearch.xpack.sql.expression.function.scalar.whitelist.InternalS # Comparison # Boolean eq(Object, Object) + Boolean nulleq(Object, Object) Boolean neq(Object, Object) Boolean lt(Object, Object) Boolean lte(Object, Object) diff --git a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessorTests.java b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessorTests.java index 394818be240..5e79877f38c 100644 --- a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessorTests.java +++ b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/expression/predicate/operator/comparison/BinaryComparisonProcessorTests.java @@ -12,6 +12,7 @@ import org.elasticsearch.xpack.sql.expression.Literal; import org.elasticsearch.xpack.sql.expression.function.scalar.Processors; import org.elasticsearch.xpack.sql.expression.gen.processor.ConstantProcessor; +import static org.elasticsearch.xpack.sql.expression.Literal.NULL; import static org.elasticsearch.xpack.sql.tree.Location.EMPTY; public class BinaryComparisonProcessorTests extends AbstractWireSerializingTestCase { @@ -42,6 +43,14 @@ public class BinaryComparisonProcessorTests extends AbstractWireSerializingTestC assertEquals(false, new Equals(EMPTY, l(3), l(4)).makePipe().asProcessor().process(null)); } + public void testNullEq() { + assertEquals(true, new NullEquals(EMPTY, l(4), l(4)).makePipe().asProcessor().process(null)); + assertEquals(false, new NullEquals(EMPTY, l(3), l(4)).makePipe().asProcessor().process(null)); + assertEquals(true, new NullEquals(EMPTY, NULL, NULL).makePipe().asProcessor().process(null)); + assertEquals(false, new NullEquals(EMPTY, l(4), NULL).makePipe().asProcessor().process(null)); + assertEquals(false, new NullEquals(EMPTY, NULL, l(4)).makePipe().asProcessor().process(null)); + } + public void testNEq() { assertEquals(false, new NotEquals(EMPTY, l(4), l(4)).makePipe().asProcessor().process(null)); assertEquals(true, new NotEquals(EMPTY, l(3), l(4)).makePipe().asProcessor().process(null)); @@ -72,12 +81,12 @@ public class BinaryComparisonProcessorTests extends AbstractWireSerializingTestC } public void testHandleNull() { - assertNull(new Equals(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); - assertNull(new NotEquals(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); - assertNull(new GreaterThan(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); - assertNull(new GreaterThanOrEqual(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); - assertNull(new LessThan(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); - assertNull(new LessThanOrEqual(EMPTY, Literal.NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new Equals(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new NotEquals(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new GreaterThan(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new GreaterThanOrEqual(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new LessThan(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); + assertNull(new LessThanOrEqual(EMPTY, NULL, l(3)).makePipe().asProcessor().process(null)); } private static Literal l(Object value) { diff --git a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/optimizer/OptimizerTests.java b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/optimizer/OptimizerTests.java index bb33c24f3e9..d4997b6c421 100644 --- a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/optimizer/OptimizerTests.java +++ b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/optimizer/OptimizerTests.java @@ -56,6 +56,7 @@ import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.In; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThan; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.LessThanOrEqual; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NotEquals; +import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NullEquals; import org.elasticsearch.xpack.sql.expression.predicate.regex.Like; import org.elasticsearch.xpack.sql.expression.predicate.regex.LikePattern; import org.elasticsearch.xpack.sql.expression.predicate.regex.RLike; @@ -272,6 +273,8 @@ public class OptimizerTests extends ESTestCase { assertEquals(Literal.FALSE, new ConstantFolding().rule(new GreaterThan(EMPTY, TWO, THREE)).canonical()); assertEquals(Literal.FALSE, new ConstantFolding().rule(new GreaterThanOrEqual(EMPTY, TWO, THREE)).canonical()); assertEquals(Literal.FALSE, new ConstantFolding().rule(new Equals(EMPTY, TWO, THREE)).canonical()); + assertEquals(Literal.FALSE, new ConstantFolding().rule(new NullEquals(EMPTY, TWO, THREE)).canonical()); + assertEquals(Literal.FALSE, new ConstantFolding().rule(new NullEquals(EMPTY, TWO, NULL)).canonical()); assertEquals(Literal.TRUE, new ConstantFolding().rule(new NotEquals(EMPTY, TWO, THREE)).canonical()); assertEquals(Literal.TRUE, new ConstantFolding().rule(new LessThanOrEqual(EMPTY, TWO, THREE)).canonical()); assertEquals(Literal.TRUE, new ConstantFolding().rule(new LessThan(EMPTY, TWO, THREE)).canonical()); @@ -438,7 +441,7 @@ public class OptimizerTests extends ESTestCase { } private List randomListOfNulls() { - return asList(randomArray(1, 10, i -> new Literal[i], () -> Literal.NULL)); + return asList(randomArray(1, 10, Literal[]::new, () -> Literal.NULL)); } public void testSimplifyCoalesceFirstLiteral() { @@ -483,6 +486,8 @@ public class OptimizerTests extends ESTestCase { public void testBinaryComparisonSimplification() { assertEquals(Literal.TRUE, new BinaryComparisonSimplification().rule(new Equals(EMPTY, FIVE, FIVE))); + assertEquals(Literal.TRUE, new BinaryComparisonSimplification().rule(new NullEquals(EMPTY, FIVE, FIVE))); + assertEquals(Literal.TRUE, new BinaryComparisonSimplification().rule(new NullEquals(EMPTY, NULL, NULL))); assertEquals(Literal.FALSE, new BinaryComparisonSimplification().rule(new NotEquals(EMPTY, FIVE, FIVE))); assertEquals(Literal.TRUE, new BinaryComparisonSimplification().rule(new GreaterThanOrEqual(EMPTY, FIVE, FIVE))); assertEquals(Literal.TRUE, new BinaryComparisonSimplification().rule(new LessThanOrEqual(EMPTY, FIVE, FIVE))); @@ -491,6 +496,25 @@ public class OptimizerTests extends ESTestCase { assertEquals(Literal.FALSE, new BinaryComparisonSimplification().rule(new LessThan(EMPTY, FIVE, FIVE))); } + public void testNullEqualsWithNullLiteralBecomesIsNull() { + BooleanLiteralsOnTheRight swapLiteralsToRight = new BooleanLiteralsOnTheRight(); + BinaryComparisonSimplification bcSimpl = new BinaryComparisonSimplification(); + FieldAttribute fa = getFieldAttribute(); + Location loc = new Location(1, 10); + + Expression e = bcSimpl.rule(swapLiteralsToRight.rule(new NullEquals(loc, fa, NULL))); + assertEquals(IsNull.class, e.getClass()); + IsNull isNull = (IsNull) e; + assertEquals(loc, isNull.location()); + assertEquals("IS_NULL(a)", isNull.name()); + + e = bcSimpl.rule(swapLiteralsToRight.rule(new NullEquals(loc, NULL, fa))); + assertEquals(IsNull.class, e.getClass()); + isNull = (IsNull) e; + assertEquals(loc, isNull.location()); + assertEquals("IS_NULL(a)", isNull.name()); + } + public void testLiteralsOnTheRight() { Alias a = new Alias(EMPTY, "a", L(10)); Expression result = new BooleanLiteralsOnTheRight().rule(new Equals(EMPTY, FIVE, a)); @@ -498,6 +522,13 @@ public class OptimizerTests extends ESTestCase { Equals eq = (Equals) result; assertEquals(a, eq.left()); assertEquals(FIVE, eq.right()); + + a = new Alias(EMPTY, "a", L(10)); + result = new BooleanLiteralsOnTheRight().rule(new NullEquals(EMPTY, FIVE, a)); + assertTrue(result instanceof NullEquals); + NullEquals nullEquals= (NullEquals) result; + assertEquals(a, nullEquals.left()); + assertEquals(FIVE, nullEquals.right()); } public void testBoolSimplifyNotIsNullAndNotIsNotNull() { @@ -1017,18 +1048,8 @@ public class OptimizerTests extends ESTestCase { assertEquals(r2, exp); } - // Equals - // a == 1 AND a == 2 -> FALSE - public void testDualEqualsConjunction() { - FieldAttribute fa = getFieldAttribute(); - Equals eq1 = new Equals(EMPTY, fa, ONE); - Equals eq2 = new Equals(EMPTY, fa, TWO); - - PropagateEquals rule = new PropagateEquals(); - Expression exp = rule.rule(new And(EMPTY, eq1, eq2)); - assertEquals(Literal.FALSE, rule.rule(exp)); - } + // Equals & NullEquals // 1 <= a < 10 AND a == 1 -> a == 1 public void testEliminateRangeByEqualsInInterval() { @@ -1041,6 +1062,44 @@ public class OptimizerTests extends ESTestCase { assertEquals(eq1, rule.rule(exp)); } + // 1 <= a < 10 AND a <=> 1 -> a <=> 1 + public void testEliminateRangeByNullEqualsInInterval() { + FieldAttribute fa = getFieldAttribute(); + NullEquals eq1 = new NullEquals(EMPTY, fa, ONE); + Range r = new Range(EMPTY, fa, ONE, true, L(10), false); + + PropagateEquals rule = new PropagateEquals(); + Expression exp = rule.rule(new And(EMPTY, eq1, r)); + assertEquals(eq1, rule.rule(exp)); + } + + + // The following tests should work only to simplify filters and + // not if the expressions are part of a projection + // See: https://github.com/elastic/elasticsearch/issues/35859 + + // a == 1 AND a == 2 -> FALSE + public void testDualEqualsConjunction() { + FieldAttribute fa = getFieldAttribute(); + Equals eq1 = new Equals(EMPTY, fa, ONE); + Equals eq2 = new Equals(EMPTY, fa, TWO); + + PropagateEquals rule = new PropagateEquals(); + Expression exp = rule.rule(new And(EMPTY, eq1, eq2)); + assertEquals(Literal.FALSE, rule.rule(exp)); + } + + // a <=> 1 AND a <=> 2 -> FALSE + public void testDualNullEqualsConjunction() { + FieldAttribute fa = getFieldAttribute(); + NullEquals eq1 = new NullEquals(EMPTY, fa, ONE); + NullEquals eq2 = new NullEquals(EMPTY, fa, TWO); + + PropagateEquals rule = new PropagateEquals(); + Expression exp = rule.rule(new And(EMPTY, eq1, eq2)); + assertEquals(Literal.FALSE, rule.rule(exp)); + } + // 1 < a < 10 AND a == 10 -> FALSE public void testEliminateRangeByEqualsOutsideInterval() { FieldAttribute fa = getFieldAttribute(); @@ -1051,4 +1110,15 @@ public class OptimizerTests extends ESTestCase { Expression exp = rule.rule(new And(EMPTY, eq1, r)); assertEquals(Literal.FALSE, rule.rule(exp)); } + + // 1 < a < 10 AND a <=> 10 -> FALSE + public void testEliminateRangeByNullEqualsOutsideInterval() { + FieldAttribute fa = getFieldAttribute(); + NullEquals eq1 = new NullEquals(EMPTY, fa, L(10)); + Range r = new Range(EMPTY, fa, ONE, false, L(10), false); + + PropagateEquals rule = new PropagateEquals(); + Expression exp = rule.rule(new And(EMPTY, eq1, r)); + assertEquals(Literal.FALSE, rule.rule(exp)); + } } diff --git a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/parser/ExpressionTests.java b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/parser/ExpressionTests.java index cb933b1fdd8..de1571e64a8 100644 --- a/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/parser/ExpressionTests.java +++ b/x-pack/plugin/sql/src/test/java/org/elasticsearch/xpack/sql/parser/ExpressionTests.java @@ -17,6 +17,7 @@ import org.elasticsearch.xpack.sql.expression.predicate.operator.arithmetic.Neg; import org.elasticsearch.xpack.sql.expression.predicate.operator.arithmetic.Sub; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.Equals; import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NotEquals; +import org.elasticsearch.xpack.sql.expression.predicate.operator.comparison.NullEquals; import org.elasticsearch.xpack.sql.type.DataType; import java.time.Duration; @@ -228,6 +229,14 @@ public class ExpressionTests extends ESTestCase { assertEquals(2, eq.children().size()); } + public void testNullEquals() { + Expression expr = parser.createExpression("a <=> 10"); + assertEquals(NullEquals.class, expr.getClass()); + NullEquals nullEquals = (NullEquals) expr; + assertEquals("(a) <=> 10", nullEquals.name()); + assertEquals(2, nullEquals.children().size()); + } + public void testNotEquals() { Expression expr = parser.createExpression("a != 10"); assertEquals(NotEquals.class, expr.getClass());