dt-sql-parser 4.1.2-beta.1 → 4.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +51 -0
- package/dist/lib/flink/FlinkSqlLexer.d.ts +2 -2
- package/dist/lib/flink/FlinkSqlLexer.js +21 -20
- package/dist/lib/flink/FlinkSqlParser.d.ts +178 -168
- package/dist/lib/flink/FlinkSqlParser.js +2799 -2741
- package/dist/lib/flink/FlinkSqlParserListener.d.ts +11 -0
- package/dist/lib/flink/FlinkSqlParserVisitor.d.ts +7 -0
- package/dist/lib/hive/HiveSqlParser.d.ts +241 -221
- package/dist/lib/hive/HiveSqlParser.js +6229 -5639
- package/dist/lib/hive/HiveSqlParserListener.d.ts +22 -0
- package/dist/lib/hive/HiveSqlParserVisitor.d.ts +14 -0
- package/dist/lib/impala/ImpalaSqlLexer.d.ts +2 -2
- package/dist/lib/impala/ImpalaSqlLexer.js +5 -5
- package/dist/lib/impala/ImpalaSqlParser.d.ts +147 -109
- package/dist/lib/impala/ImpalaSqlParser.js +3448 -3234
- package/dist/lib/impala/ImpalaSqlParserListener.d.ts +44 -0
- package/dist/lib/impala/ImpalaSqlParserVisitor.d.ts +28 -0
- package/dist/lib/mysql/MySqlLexer.d.ts +2 -2
- package/dist/lib/mysql/MySqlLexer.js +43 -43
- package/dist/lib/mysql/MySqlParser.d.ts +2 -2
- package/dist/lib/mysql/MySqlParser.js +42 -42
- package/dist/lib/postgresql/PostgreSqlLexer.d.ts +14 -15
- package/dist/lib/postgresql/PostgreSqlLexer.js +2077 -2092
- package/dist/lib/postgresql/PostgreSqlParser.d.ts +152 -131
- package/dist/lib/postgresql/PostgreSqlParser.js +10052 -9925
- package/dist/lib/postgresql/PostgreSqlParserListener.d.ts +22 -0
- package/dist/lib/postgresql/PostgreSqlParserVisitor.d.ts +14 -0
- package/dist/lib/spark/SparkSqlLexer.d.ts +2 -2
- package/dist/lib/spark/SparkSqlLexer.js +6 -6
- package/dist/lib/spark/SparkSqlParser.d.ts +391 -623
- package/dist/lib/spark/SparkSqlParser.js +6749 -8109
- package/dist/lib/spark/SparkSqlParserListener.d.ts +38 -326
- package/dist/lib/spark/SparkSqlParserVisitor.d.ts +24 -207
- package/dist/lib/trino/TrinoSqlLexer.d.ts +2 -2
- package/dist/lib/trino/TrinoSqlLexer.js +5 -5
- package/dist/lib/trino/TrinoSqlListener.d.ts +44 -0
- package/dist/lib/trino/TrinoSqlParser.d.ts +182 -153
- package/dist/lib/trino/TrinoSqlParser.js +4758 -4599
- package/dist/lib/trino/TrinoSqlVisitor.d.ts +28 -0
- package/dist/parser/common/basicSQL.d.ts +43 -9
- package/dist/parser/common/basicSQL.js +147 -40
- package/dist/parser/common/semanticContextCollector.d.ts +50 -0
- package/dist/parser/common/semanticContextCollector.js +202 -0
- package/dist/parser/common/tokenUtils.d.ts +12 -0
- package/dist/parser/common/tokenUtils.js +38 -0
- package/dist/parser/common/types.d.ts +30 -1
- package/dist/parser/common/types.js +11 -0
- package/dist/parser/flink/flinkErrorListener.js +14 -2
- package/dist/parser/flink/flinkSemanticContextCollector.d.ts +9 -0
- package/dist/parser/flink/flinkSemanticContextCollector.js +14 -0
- package/dist/parser/flink/index.d.ts +4 -2
- package/dist/parser/flink/index.js +32 -14
- package/dist/parser/hive/hiveErrorListener.js +9 -3
- package/dist/parser/hive/hiveSemanticContextCollector.d.ts +9 -0
- package/dist/parser/hive/hiveSemanticContextCollector.js +14 -0
- package/dist/parser/hive/index.d.ts +4 -2
- package/dist/parser/hive/index.js +29 -14
- package/dist/parser/impala/ImpalaErrorListener.js +8 -2
- package/dist/parser/impala/impalaSemanticContextCollector.d.ts +9 -0
- package/dist/parser/impala/impalaSemanticContextCollector.js +14 -0
- package/dist/parser/impala/index.d.ts +4 -2
- package/dist/parser/impala/index.js +21 -14
- package/dist/parser/mysql/index.d.ts +4 -2
- package/dist/parser/mysql/index.js +10 -14
- package/dist/parser/mysql/mysqlErrorListener.js +6 -2
- package/dist/parser/mysql/mysqlSemanticContextCollector.d.ts +9 -0
- package/dist/parser/mysql/mysqlSemanticContextCollector.js +14 -0
- package/dist/parser/postgresql/index.d.ts +4 -2
- package/dist/parser/postgresql/index.js +23 -14
- package/dist/parser/postgresql/postgreErrorListener.js +9 -3
- package/dist/parser/postgresql/postgreSemanticContextCollector.d.ts +9 -0
- package/dist/parser/postgresql/postgreSemanticContextCollector.js +14 -0
- package/dist/parser/spark/index.d.ts +4 -2
- package/dist/parser/spark/index.js +26 -14
- package/dist/parser/spark/sparkErrorListener.js +9 -3
- package/dist/parser/spark/sparkSemanticContextCollector.d.ts +9 -0
- package/dist/parser/spark/sparkSemanticContextCollector.js +14 -0
- package/dist/parser/trino/index.d.ts +4 -2
- package/dist/parser/trino/index.js +22 -14
- package/dist/parser/trino/trinoErrorListener.js +9 -3
- package/dist/parser/trino/trinoSemanticContextCollector.d.ts +9 -0
- package/dist/parser/trino/trinoSemanticContextCollector.js +14 -0
- package/package.json +2 -1
|
@@ -128,6 +128,7 @@ import { ColumnNameTypeOrConstraintListContext } from "./HiveSqlParser.js";
|
|
|
128
128
|
import { ColumnNameColonTypeListContext } from "./HiveSqlParser.js";
|
|
129
129
|
import { ColumnNameListContext } from "./HiveSqlParser.js";
|
|
130
130
|
import { ColumnNameContext } from "./HiveSqlParser.js";
|
|
131
|
+
import { ColumnNamePathContext } from "./HiveSqlParser.js";
|
|
131
132
|
import { ColumnNameCreateContext } from "./HiveSqlParser.js";
|
|
132
133
|
import { ExtColumnNameContext } from "./HiveSqlParser.js";
|
|
133
134
|
import { ColumnNameOrderListContext } from "./HiveSqlParser.js";
|
|
@@ -273,6 +274,7 @@ import { ExpressionsContext } from "./HiveSqlParser.js";
|
|
|
273
274
|
import { ExpressionsInParenthesisContext } from "./HiveSqlParser.js";
|
|
274
275
|
import { ExpressionsNotInParenthesisContext } from "./HiveSqlParser.js";
|
|
275
276
|
import { OrderByClauseContext } from "./HiveSqlParser.js";
|
|
277
|
+
import { PartitionByClauseContext } from "./HiveSqlParser.js";
|
|
276
278
|
import { ClusterByClauseContext } from "./HiveSqlParser.js";
|
|
277
279
|
import { DistributeByClauseContext } from "./HiveSqlParser.js";
|
|
278
280
|
import { SortByClauseContext } from "./HiveSqlParser.js";
|
|
@@ -1642,6 +1644,16 @@ export declare class HiveSqlParserListener implements ParseTreeListener {
|
|
|
1642
1644
|
* @param ctx the parse tree
|
|
1643
1645
|
*/
|
|
1644
1646
|
exitColumnName?: (ctx: ColumnNameContext) => void;
|
|
1647
|
+
/**
|
|
1648
|
+
* Enter a parse tree produced by `HiveSqlParser.columnNamePath`.
|
|
1649
|
+
* @param ctx the parse tree
|
|
1650
|
+
*/
|
|
1651
|
+
enterColumnNamePath?: (ctx: ColumnNamePathContext) => void;
|
|
1652
|
+
/**
|
|
1653
|
+
* Exit a parse tree produced by `HiveSqlParser.columnNamePath`.
|
|
1654
|
+
* @param ctx the parse tree
|
|
1655
|
+
*/
|
|
1656
|
+
exitColumnNamePath?: (ctx: ColumnNamePathContext) => void;
|
|
1645
1657
|
/**
|
|
1646
1658
|
* Enter a parse tree produced by `HiveSqlParser.columnNameCreate`.
|
|
1647
1659
|
* @param ctx the parse tree
|
|
@@ -3100,6 +3112,16 @@ export declare class HiveSqlParserListener implements ParseTreeListener {
|
|
|
3100
3112
|
* @param ctx the parse tree
|
|
3101
3113
|
*/
|
|
3102
3114
|
exitOrderByClause?: (ctx: OrderByClauseContext) => void;
|
|
3115
|
+
/**
|
|
3116
|
+
* Enter a parse tree produced by `HiveSqlParser.partitionByClause`.
|
|
3117
|
+
* @param ctx the parse tree
|
|
3118
|
+
*/
|
|
3119
|
+
enterPartitionByClause?: (ctx: PartitionByClauseContext) => void;
|
|
3120
|
+
/**
|
|
3121
|
+
* Exit a parse tree produced by `HiveSqlParser.partitionByClause`.
|
|
3122
|
+
* @param ctx the parse tree
|
|
3123
|
+
*/
|
|
3124
|
+
exitPartitionByClause?: (ctx: PartitionByClauseContext) => void;
|
|
3103
3125
|
/**
|
|
3104
3126
|
* Enter a parse tree produced by `HiveSqlParser.clusterByClause`.
|
|
3105
3127
|
* @param ctx the parse tree
|
|
@@ -128,6 +128,7 @@ import { ColumnNameTypeOrConstraintListContext } from "./HiveSqlParser.js";
|
|
|
128
128
|
import { ColumnNameColonTypeListContext } from "./HiveSqlParser.js";
|
|
129
129
|
import { ColumnNameListContext } from "./HiveSqlParser.js";
|
|
130
130
|
import { ColumnNameContext } from "./HiveSqlParser.js";
|
|
131
|
+
import { ColumnNamePathContext } from "./HiveSqlParser.js";
|
|
131
132
|
import { ColumnNameCreateContext } from "./HiveSqlParser.js";
|
|
132
133
|
import { ExtColumnNameContext } from "./HiveSqlParser.js";
|
|
133
134
|
import { ColumnNameOrderListContext } from "./HiveSqlParser.js";
|
|
@@ -273,6 +274,7 @@ import { ExpressionsContext } from "./HiveSqlParser.js";
|
|
|
273
274
|
import { ExpressionsInParenthesisContext } from "./HiveSqlParser.js";
|
|
274
275
|
import { ExpressionsNotInParenthesisContext } from "./HiveSqlParser.js";
|
|
275
276
|
import { OrderByClauseContext } from "./HiveSqlParser.js";
|
|
277
|
+
import { PartitionByClauseContext } from "./HiveSqlParser.js";
|
|
276
278
|
import { ClusterByClauseContext } from "./HiveSqlParser.js";
|
|
277
279
|
import { DistributeByClauseContext } from "./HiveSqlParser.js";
|
|
278
280
|
import { SortByClauseContext } from "./HiveSqlParser.js";
|
|
@@ -1129,6 +1131,12 @@ export declare class HiveSqlParserVisitor<Result> extends AbstractParseTreeVisit
|
|
|
1129
1131
|
* @return the visitor result
|
|
1130
1132
|
*/
|
|
1131
1133
|
visitColumnName?: (ctx: ColumnNameContext) => Result;
|
|
1134
|
+
/**
|
|
1135
|
+
* Visit a parse tree produced by `HiveSqlParser.columnNamePath`.
|
|
1136
|
+
* @param ctx the parse tree
|
|
1137
|
+
* @return the visitor result
|
|
1138
|
+
*/
|
|
1139
|
+
visitColumnNamePath?: (ctx: ColumnNamePathContext) => Result;
|
|
1132
1140
|
/**
|
|
1133
1141
|
* Visit a parse tree produced by `HiveSqlParser.columnNameCreate`.
|
|
1134
1142
|
* @param ctx the parse tree
|
|
@@ -2003,6 +2011,12 @@ export declare class HiveSqlParserVisitor<Result> extends AbstractParseTreeVisit
|
|
|
2003
2011
|
* @return the visitor result
|
|
2004
2012
|
*/
|
|
2005
2013
|
visitOrderByClause?: (ctx: OrderByClauseContext) => Result;
|
|
2014
|
+
/**
|
|
2015
|
+
* Visit a parse tree produced by `HiveSqlParser.partitionByClause`.
|
|
2016
|
+
* @param ctx the parse tree
|
|
2017
|
+
* @return the visitor result
|
|
2018
|
+
*/
|
|
2019
|
+
visitPartitionByClause?: (ctx: PartitionByClauseContext) => Result;
|
|
2006
2020
|
/**
|
|
2007
2021
|
* Visit a parse tree produced by `HiveSqlParser.clusterByClause`.
|
|
2008
2022
|
* @param ctx the parse tree
|
|
@@ -286,9 +286,9 @@ export declare class ImpalaSqlLexer extends antlr.Lexer {
|
|
|
286
286
|
static readonly TIME_WITH_TIME_ZONE = 284;
|
|
287
287
|
static readonly TIMESTAMP_WITH_TIME_ZONE = 285;
|
|
288
288
|
static readonly DOUBLE_PRECISION = 286;
|
|
289
|
-
static readonly
|
|
289
|
+
static readonly LINE_COMMENT = 287;
|
|
290
290
|
static readonly BRACKETED_COMMENT = 288;
|
|
291
|
-
static readonly
|
|
291
|
+
static readonly WHITE_SPACE = 289;
|
|
292
292
|
static readonly channelNames: string[];
|
|
293
293
|
static readonly literalNames: (string | null)[];
|
|
294
294
|
static readonly symbolicNames: (string | null)[];
|
|
@@ -309,9 +309,9 @@ ImpalaSqlLexer.BACKQUOTED_IDENTIFIER = 283;
|
|
|
309
309
|
ImpalaSqlLexer.TIME_WITH_TIME_ZONE = 284;
|
|
310
310
|
ImpalaSqlLexer.TIMESTAMP_WITH_TIME_ZONE = 285;
|
|
311
311
|
ImpalaSqlLexer.DOUBLE_PRECISION = 286;
|
|
312
|
-
ImpalaSqlLexer.
|
|
312
|
+
ImpalaSqlLexer.LINE_COMMENT = 287;
|
|
313
313
|
ImpalaSqlLexer.BRACKETED_COMMENT = 288;
|
|
314
|
-
ImpalaSqlLexer.
|
|
314
|
+
ImpalaSqlLexer.WHITE_SPACE = 289;
|
|
315
315
|
ImpalaSqlLexer.channelNames = [
|
|
316
316
|
"DEFAULT_TOKEN_CHANNEL", "HIDDEN"
|
|
317
317
|
];
|
|
@@ -421,7 +421,7 @@ ImpalaSqlLexer.symbolicNames = [
|
|
|
421
421
|
"INTEGER_VALUE", "DECIMAL_VALUE", "DOUBLE_VALUE", "IDENTIFIER",
|
|
422
422
|
"DIGIT_IDENTIFIER", "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER",
|
|
423
423
|
"TIME_WITH_TIME_ZONE", "TIMESTAMP_WITH_TIME_ZONE", "DOUBLE_PRECISION",
|
|
424
|
-
"
|
|
424
|
+
"LINE_COMMENT", "BRACKETED_COMMENT", "WHITE_SPACE"
|
|
425
425
|
];
|
|
426
426
|
ImpalaSqlLexer.modeNames = [
|
|
427
427
|
"DEFAULT_MODE",
|
|
@@ -482,8 +482,8 @@ ImpalaSqlLexer.ruleNames = [
|
|
|
482
482
|
"INTEGER_VALUE", "DECIMAL_VALUE", "DOUBLE_VALUE", "IDENTIFIER",
|
|
483
483
|
"DIGIT_IDENTIFIER", "QUOTED_IDENTIFIER", "BACKQUOTED_IDENTIFIER",
|
|
484
484
|
"TIME_WITH_TIME_ZONE", "TIMESTAMP_WITH_TIME_ZONE", "DOUBLE_PRECISION",
|
|
485
|
-
"EXPONENT", "DIGIT", "LETTER", "
|
|
486
|
-
"
|
|
485
|
+
"EXPONENT", "DIGIT", "LETTER", "LINE_COMMENT", "BRACKETED_COMMENT",
|
|
486
|
+
"WHITE_SPACE",
|
|
487
487
|
];
|
|
488
488
|
ImpalaSqlLexer._serializedATN = [
|
|
489
489
|
4, 0, 289, 2741, 6, -1, 2, 0, 7, 0, 2, 1, 7, 1, 2, 2, 7, 2, 2, 3, 7, 3, 2, 4, 7, 4, 2, 5, 7,
|
|
@@ -290,9 +290,9 @@ export declare class ImpalaSqlParser extends SQLParserBase {
|
|
|
290
290
|
static readonly TIME_WITH_TIME_ZONE = 284;
|
|
291
291
|
static readonly TIMESTAMP_WITH_TIME_ZONE = 285;
|
|
292
292
|
static readonly DOUBLE_PRECISION = 286;
|
|
293
|
-
static readonly
|
|
293
|
+
static readonly LINE_COMMENT = 287;
|
|
294
294
|
static readonly BRACKETED_COMMENT = 288;
|
|
295
|
-
static readonly
|
|
295
|
+
static readonly WHITE_SPACE = 289;
|
|
296
296
|
static readonly RULE_program = 0;
|
|
297
297
|
static readonly RULE_singleStatement = 1;
|
|
298
298
|
static readonly RULE_sqlStatement = 2;
|
|
@@ -390,94 +390,98 @@ export declare class ImpalaSqlParser extends SQLParserBase {
|
|
|
390
390
|
static readonly RULE_viewNamePath = 94;
|
|
391
391
|
static readonly RULE_functionNamePath = 95;
|
|
392
392
|
static readonly RULE_columnNamePath = 96;
|
|
393
|
-
static readonly
|
|
394
|
-
static readonly
|
|
395
|
-
static readonly
|
|
396
|
-
static readonly
|
|
397
|
-
static readonly
|
|
398
|
-
static readonly
|
|
399
|
-
static readonly
|
|
400
|
-
static readonly
|
|
401
|
-
static readonly
|
|
402
|
-
static readonly
|
|
403
|
-
static readonly
|
|
404
|
-
static readonly
|
|
405
|
-
static readonly
|
|
406
|
-
static readonly
|
|
407
|
-
static readonly
|
|
408
|
-
static readonly
|
|
409
|
-
static readonly
|
|
410
|
-
static readonly
|
|
411
|
-
static readonly
|
|
412
|
-
static readonly
|
|
413
|
-
static readonly
|
|
414
|
-
static readonly
|
|
415
|
-
static readonly
|
|
416
|
-
static readonly
|
|
417
|
-
static readonly
|
|
418
|
-
static readonly
|
|
419
|
-
static readonly
|
|
420
|
-
static readonly
|
|
421
|
-
static readonly
|
|
422
|
-
static readonly
|
|
423
|
-
static readonly
|
|
424
|
-
static readonly
|
|
425
|
-
static readonly
|
|
426
|
-
static readonly
|
|
427
|
-
static readonly
|
|
428
|
-
static readonly
|
|
429
|
-
static readonly
|
|
430
|
-
static readonly
|
|
431
|
-
static readonly
|
|
432
|
-
static readonly
|
|
433
|
-
static readonly
|
|
434
|
-
static readonly
|
|
435
|
-
static readonly
|
|
436
|
-
static readonly
|
|
437
|
-
static readonly
|
|
438
|
-
static readonly
|
|
439
|
-
static readonly
|
|
440
|
-
static readonly
|
|
441
|
-
static readonly
|
|
442
|
-
static readonly
|
|
443
|
-
static readonly
|
|
444
|
-
static readonly
|
|
445
|
-
static readonly
|
|
446
|
-
static readonly
|
|
447
|
-
static readonly
|
|
448
|
-
static readonly
|
|
449
|
-
static readonly
|
|
450
|
-
static readonly
|
|
451
|
-
static readonly
|
|
452
|
-
static readonly
|
|
453
|
-
static readonly
|
|
454
|
-
static readonly
|
|
455
|
-
static readonly
|
|
456
|
-
static readonly
|
|
457
|
-
static readonly
|
|
458
|
-
static readonly
|
|
459
|
-
static readonly
|
|
460
|
-
static readonly
|
|
461
|
-
static readonly
|
|
462
|
-
static readonly
|
|
463
|
-
static readonly
|
|
464
|
-
static readonly
|
|
465
|
-
static readonly
|
|
466
|
-
static readonly
|
|
467
|
-
static readonly
|
|
468
|
-
static readonly
|
|
469
|
-
static readonly
|
|
470
|
-
static readonly
|
|
471
|
-
static readonly
|
|
472
|
-
static readonly
|
|
473
|
-
static readonly
|
|
474
|
-
static readonly
|
|
475
|
-
static readonly
|
|
476
|
-
static readonly
|
|
477
|
-
static readonly
|
|
478
|
-
static readonly
|
|
479
|
-
static readonly
|
|
480
|
-
static readonly
|
|
393
|
+
static readonly RULE_columnName = 97;
|
|
394
|
+
static readonly RULE_tableOrViewPath = 98;
|
|
395
|
+
static readonly RULE_createCommonItem = 99;
|
|
396
|
+
static readonly RULE_assignmentList = 100;
|
|
397
|
+
static readonly RULE_assignmentItem = 101;
|
|
398
|
+
static readonly RULE_viewColumns = 102;
|
|
399
|
+
static readonly RULE_viewColumnItem = 103;
|
|
400
|
+
static readonly RULE_queryStatement = 104;
|
|
401
|
+
static readonly RULE_with = 105;
|
|
402
|
+
static readonly RULE_constraintSpecification = 106;
|
|
403
|
+
static readonly RULE_foreignKeySpecification = 107;
|
|
404
|
+
static readonly RULE_columnSpec = 108;
|
|
405
|
+
static readonly RULE_columnDefinition = 109;
|
|
406
|
+
static readonly RULE_kuduTableElement = 110;
|
|
407
|
+
static readonly RULE_kuduColumnDefinition = 111;
|
|
408
|
+
static readonly RULE_commentClause = 112;
|
|
409
|
+
static readonly RULE_columnSpecWithKudu = 113;
|
|
410
|
+
static readonly RULE_createColumnSpecWithKudu = 114;
|
|
411
|
+
static readonly RULE_kuduAttributes = 115;
|
|
412
|
+
static readonly RULE_kuduStorageAttr = 116;
|
|
413
|
+
static readonly RULE_statsKey = 117;
|
|
414
|
+
static readonly RULE_fileFormat = 118;
|
|
415
|
+
static readonly RULE_kuduPartitionClause = 119;
|
|
416
|
+
static readonly RULE_hashClause = 120;
|
|
417
|
+
static readonly RULE_rangeClause = 121;
|
|
418
|
+
static readonly RULE_kuduPartitionSpec = 122;
|
|
419
|
+
static readonly RULE_cacheSpec = 123;
|
|
420
|
+
static readonly RULE_rangeOperator = 124;
|
|
421
|
+
static readonly RULE_partitionCol = 125;
|
|
422
|
+
static readonly RULE_likeClause = 126;
|
|
423
|
+
static readonly RULE_properties = 127;
|
|
424
|
+
static readonly RULE_partitionedBy = 128;
|
|
425
|
+
static readonly RULE_sortedBy = 129;
|
|
426
|
+
static readonly RULE_rowFormat = 130;
|
|
427
|
+
static readonly RULE_property = 131;
|
|
428
|
+
static readonly RULE_queryNoWith = 132;
|
|
429
|
+
static readonly RULE_queryTerm = 133;
|
|
430
|
+
static readonly RULE_queryPrimary = 134;
|
|
431
|
+
static readonly RULE_sortItem = 135;
|
|
432
|
+
static readonly RULE_querySpecification = 136;
|
|
433
|
+
static readonly RULE_whereClause = 137;
|
|
434
|
+
static readonly RULE_havingClause = 138;
|
|
435
|
+
static readonly RULE_groupBy = 139;
|
|
436
|
+
static readonly RULE_groupingElement = 140;
|
|
437
|
+
static readonly RULE_groupingSet = 141;
|
|
438
|
+
static readonly RULE_namedQuery = 142;
|
|
439
|
+
static readonly RULE_setQuantifier = 143;
|
|
440
|
+
static readonly RULE_selectItem = 144;
|
|
441
|
+
static readonly RULE_relation = 145;
|
|
442
|
+
static readonly RULE_joinType = 146;
|
|
443
|
+
static readonly RULE_joinCriteria = 147;
|
|
444
|
+
static readonly RULE_sampledRelation = 148;
|
|
445
|
+
static readonly RULE_sampleType = 149;
|
|
446
|
+
static readonly RULE_aliasedRelation = 150;
|
|
447
|
+
static readonly RULE_columnAliases = 151;
|
|
448
|
+
static readonly RULE_relationPrimary = 152;
|
|
449
|
+
static readonly RULE_subQueryRelation = 153;
|
|
450
|
+
static readonly RULE_unnest = 154;
|
|
451
|
+
static readonly RULE_parenthesizedRelation = 155;
|
|
452
|
+
static readonly RULE_columnItem = 156;
|
|
453
|
+
static readonly RULE_expression = 157;
|
|
454
|
+
static readonly RULE_booleanExpression = 158;
|
|
455
|
+
static readonly RULE_predicate = 159;
|
|
456
|
+
static readonly RULE_valueExpression = 160;
|
|
457
|
+
static readonly RULE_primaryExpression = 161;
|
|
458
|
+
static readonly RULE_stringLiteral = 162;
|
|
459
|
+
static readonly RULE_comparisonOperator = 163;
|
|
460
|
+
static readonly RULE_comparisonQuantifier = 164;
|
|
461
|
+
static readonly RULE_booleanValue = 165;
|
|
462
|
+
static readonly RULE_interval = 166;
|
|
463
|
+
static readonly RULE_intervalField = 167;
|
|
464
|
+
static readonly RULE_normalForm = 168;
|
|
465
|
+
static readonly RULE_type = 169;
|
|
466
|
+
static readonly RULE_dataType = 170;
|
|
467
|
+
static readonly RULE_typeParameter = 171;
|
|
468
|
+
static readonly RULE_baseType = 172;
|
|
469
|
+
static readonly RULE_whenClause = 173;
|
|
470
|
+
static readonly RULE_filter = 174;
|
|
471
|
+
static readonly RULE_partitionByClause = 175;
|
|
472
|
+
static readonly RULE_over = 176;
|
|
473
|
+
static readonly RULE_windowFrame = 177;
|
|
474
|
+
static readonly RULE_frameBound = 178;
|
|
475
|
+
static readonly RULE_pathElement = 179;
|
|
476
|
+
static readonly RULE_pathSpecification = 180;
|
|
477
|
+
static readonly RULE_privilege = 181;
|
|
478
|
+
static readonly RULE_objectType = 182;
|
|
479
|
+
static readonly RULE_qualifiedName = 183;
|
|
480
|
+
static readonly RULE_principal = 184;
|
|
481
|
+
static readonly RULE_identifier = 185;
|
|
482
|
+
static readonly RULE_number = 186;
|
|
483
|
+
static readonly RULE_reservedKeywordsUsedAsFuncName = 187;
|
|
484
|
+
static readonly RULE_nonReserved = 188;
|
|
481
485
|
static readonly literalNames: (string | null)[];
|
|
482
486
|
static readonly symbolicNames: (string | null)[];
|
|
483
487
|
static readonly ruleNames: string[];
|
|
@@ -585,6 +589,7 @@ export declare class ImpalaSqlParser extends SQLParserBase {
|
|
|
585
589
|
viewNamePath(): ViewNamePathContext;
|
|
586
590
|
functionNamePath(): FunctionNamePathContext;
|
|
587
591
|
columnNamePath(): ColumnNamePathContext;
|
|
592
|
+
columnName(): ColumnNameContext;
|
|
588
593
|
tableOrViewPath(): TableOrViewPathContext;
|
|
589
594
|
createCommonItem(): CreateCommonItemContext;
|
|
590
595
|
assignmentList(): AssignmentListContext;
|
|
@@ -625,6 +630,8 @@ export declare class ImpalaSqlParser extends SQLParserBase {
|
|
|
625
630
|
queryPrimary(): QueryPrimaryContext;
|
|
626
631
|
sortItem(): SortItemContext;
|
|
627
632
|
querySpecification(): QuerySpecificationContext;
|
|
633
|
+
whereClause(): WhereClauseContext;
|
|
634
|
+
havingClause(): HavingClauseContext;
|
|
628
635
|
groupBy(): GroupByContext;
|
|
629
636
|
groupingElement(): GroupingElementContext;
|
|
630
637
|
groupingSet(): GroupingSetContext;
|
|
@@ -666,6 +673,7 @@ export declare class ImpalaSqlParser extends SQLParserBase {
|
|
|
666
673
|
baseType(): BaseTypeContext;
|
|
667
674
|
whenClause(): WhenClauseContext;
|
|
668
675
|
filter(): FilterContext;
|
|
676
|
+
partitionByClause(): PartitionByClauseContext;
|
|
669
677
|
over(): OverContext;
|
|
670
678
|
windowFrame(): WindowFrameContext;
|
|
671
679
|
frameBound(): FrameBoundContext;
|
|
@@ -1545,8 +1553,7 @@ export declare class DeleteContext extends antlr.ParserRuleContext {
|
|
|
1545
1553
|
KW_DELETE(): antlr.TerminalNode;
|
|
1546
1554
|
tableNamePath(): TableNamePathContext;
|
|
1547
1555
|
KW_FROM(): antlr.TerminalNode | null;
|
|
1548
|
-
|
|
1549
|
-
booleanExpression(): BooleanExpressionContext | null;
|
|
1556
|
+
whereClause(): WhereClauseContext | null;
|
|
1550
1557
|
get ruleIndex(): number;
|
|
1551
1558
|
enterRule(listener: ImpalaSqlParserListener): void;
|
|
1552
1559
|
exitRule(listener: ImpalaSqlParserListener): void;
|
|
@@ -1560,8 +1567,7 @@ export declare class DeleteTableRefContext extends antlr.ParserRuleContext {
|
|
|
1560
1567
|
identifier(): IdentifierContext | null;
|
|
1561
1568
|
relation(): RelationContext[];
|
|
1562
1569
|
relation(i: number): RelationContext | null;
|
|
1563
|
-
|
|
1564
|
-
booleanExpression(): BooleanExpressionContext | null;
|
|
1570
|
+
whereClause(): WhereClauseContext | null;
|
|
1565
1571
|
KW_AS(): antlr.TerminalNode | null;
|
|
1566
1572
|
COMMA(): antlr.TerminalNode[];
|
|
1567
1573
|
COMMA(i: number): antlr.TerminalNode | null;
|
|
@@ -1579,8 +1585,7 @@ export declare class UpdateStatementContext extends antlr.ParserRuleContext {
|
|
|
1579
1585
|
KW_FROM(): antlr.TerminalNode | null;
|
|
1580
1586
|
relation(): RelationContext[];
|
|
1581
1587
|
relation(i: number): RelationContext | null;
|
|
1582
|
-
|
|
1583
|
-
booleanExpression(): BooleanExpressionContext | null;
|
|
1588
|
+
whereClause(): WhereClauseContext | null;
|
|
1584
1589
|
COMMA(): antlr.TerminalNode[];
|
|
1585
1590
|
COMMA(i: number): antlr.TerminalNode | null;
|
|
1586
1591
|
get ruleIndex(): number;
|
|
@@ -2103,6 +2108,14 @@ export declare class ColumnNamePathContext extends antlr.ParserRuleContext {
|
|
|
2103
2108
|
exitRule(listener: ImpalaSqlParserListener): void;
|
|
2104
2109
|
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
2105
2110
|
}
|
|
2111
|
+
export declare class ColumnNameContext extends antlr.ParserRuleContext {
|
|
2112
|
+
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
2113
|
+
qualifiedName(): QualifiedNameContext;
|
|
2114
|
+
get ruleIndex(): number;
|
|
2115
|
+
enterRule(listener: ImpalaSqlParserListener): void;
|
|
2116
|
+
exitRule(listener: ImpalaSqlParserListener): void;
|
|
2117
|
+
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
2118
|
+
}
|
|
2106
2119
|
export declare class TableOrViewPathContext extends antlr.ParserRuleContext {
|
|
2107
2120
|
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
2108
2121
|
tableNamePath(): TableNamePathContext | null;
|
|
@@ -2645,8 +2658,6 @@ export declare class SortItemContext extends antlr.ParserRuleContext {
|
|
|
2645
2658
|
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
2646
2659
|
}
|
|
2647
2660
|
export declare class QuerySpecificationContext extends antlr.ParserRuleContext {
|
|
2648
|
-
_where?: BooleanExpressionContext;
|
|
2649
|
-
_having?: BooleanExpressionContext;
|
|
2650
2661
|
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
2651
2662
|
KW_SELECT(): antlr.TerminalNode;
|
|
2652
2663
|
selectItem(): SelectItemContext[];
|
|
@@ -2658,13 +2669,31 @@ export declare class QuerySpecificationContext extends antlr.ParserRuleContext {
|
|
|
2658
2669
|
KW_FROM(): antlr.TerminalNode | null;
|
|
2659
2670
|
relation(): RelationContext[];
|
|
2660
2671
|
relation(i: number): RelationContext | null;
|
|
2661
|
-
|
|
2672
|
+
whereClause(): WhereClauseContext | null;
|
|
2662
2673
|
KW_GROUP(): antlr.TerminalNode | null;
|
|
2663
2674
|
KW_BY(): antlr.TerminalNode | null;
|
|
2664
2675
|
groupBy(): GroupByContext | null;
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2676
|
+
havingClause(): HavingClauseContext | null;
|
|
2677
|
+
get ruleIndex(): number;
|
|
2678
|
+
enterRule(listener: ImpalaSqlParserListener): void;
|
|
2679
|
+
exitRule(listener: ImpalaSqlParserListener): void;
|
|
2680
|
+
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
2681
|
+
}
|
|
2682
|
+
export declare class WhereClauseContext extends antlr.ParserRuleContext {
|
|
2683
|
+
_where?: BooleanExpressionContext;
|
|
2684
|
+
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
2685
|
+
KW_WHERE(): antlr.TerminalNode;
|
|
2686
|
+
booleanExpression(): BooleanExpressionContext;
|
|
2687
|
+
get ruleIndex(): number;
|
|
2688
|
+
enterRule(listener: ImpalaSqlParserListener): void;
|
|
2689
|
+
exitRule(listener: ImpalaSqlParserListener): void;
|
|
2690
|
+
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
2691
|
+
}
|
|
2692
|
+
export declare class HavingClauseContext extends antlr.ParserRuleContext {
|
|
2693
|
+
_having?: BooleanExpressionContext;
|
|
2694
|
+
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
2695
|
+
KW_HAVING(): antlr.TerminalNode;
|
|
2696
|
+
booleanExpression(): BooleanExpressionContext;
|
|
2668
2697
|
get ruleIndex(): number;
|
|
2669
2698
|
enterRule(listener: ImpalaSqlParserListener): void;
|
|
2670
2699
|
exitRule(listener: ImpalaSqlParserListener): void;
|
|
@@ -3273,7 +3302,7 @@ export declare class SimpleCaseContext extends PrimaryExpressionContext {
|
|
|
3273
3302
|
}
|
|
3274
3303
|
export declare class ColumnReferenceContext extends PrimaryExpressionContext {
|
|
3275
3304
|
constructor(ctx: PrimaryExpressionContext);
|
|
3276
|
-
|
|
3305
|
+
columnName(): ColumnNameContext;
|
|
3277
3306
|
enterRule(listener: ImpalaSqlParserListener): void;
|
|
3278
3307
|
exitRule(listener: ImpalaSqlParserListener): void;
|
|
3279
3308
|
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
@@ -3622,17 +3651,27 @@ export declare class FilterContext extends antlr.ParserRuleContext {
|
|
|
3622
3651
|
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
3623
3652
|
KW_FILTER(): antlr.TerminalNode;
|
|
3624
3653
|
LPAREN(): antlr.TerminalNode;
|
|
3625
|
-
|
|
3626
|
-
booleanExpression(): BooleanExpressionContext;
|
|
3654
|
+
whereClause(): WhereClauseContext;
|
|
3627
3655
|
RPAREN(): antlr.TerminalNode;
|
|
3628
3656
|
get ruleIndex(): number;
|
|
3629
3657
|
enterRule(listener: ImpalaSqlParserListener): void;
|
|
3630
3658
|
exitRule(listener: ImpalaSqlParserListener): void;
|
|
3631
3659
|
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
3632
3660
|
}
|
|
3633
|
-
export declare class
|
|
3661
|
+
export declare class PartitionByClauseContext extends antlr.ParserRuleContext {
|
|
3634
3662
|
_expression?: ExpressionContext;
|
|
3635
3663
|
_partition: ExpressionContext[];
|
|
3664
|
+
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
3665
|
+
expression(): ExpressionContext[];
|
|
3666
|
+
expression(i: number): ExpressionContext | null;
|
|
3667
|
+
COMMA(): antlr.TerminalNode[];
|
|
3668
|
+
COMMA(i: number): antlr.TerminalNode | null;
|
|
3669
|
+
get ruleIndex(): number;
|
|
3670
|
+
enterRule(listener: ImpalaSqlParserListener): void;
|
|
3671
|
+
exitRule(listener: ImpalaSqlParserListener): void;
|
|
3672
|
+
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
3673
|
+
}
|
|
3674
|
+
export declare class OverContext extends antlr.ParserRuleContext {
|
|
3636
3675
|
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
3637
3676
|
KW_OVER(): antlr.TerminalNode;
|
|
3638
3677
|
LPAREN(): antlr.TerminalNode;
|
|
@@ -3640,12 +3679,11 @@ export declare class OverContext extends antlr.ParserRuleContext {
|
|
|
3640
3679
|
KW_PARTITION(): antlr.TerminalNode | null;
|
|
3641
3680
|
KW_BY(): antlr.TerminalNode[];
|
|
3642
3681
|
KW_BY(i: number): antlr.TerminalNode | null;
|
|
3682
|
+
partitionByClause(): PartitionByClauseContext | null;
|
|
3643
3683
|
KW_ORDER(): antlr.TerminalNode | null;
|
|
3644
3684
|
sortItem(): SortItemContext[];
|
|
3645
3685
|
sortItem(i: number): SortItemContext | null;
|
|
3646
3686
|
windowFrame(): WindowFrameContext | null;
|
|
3647
|
-
expression(): ExpressionContext[];
|
|
3648
|
-
expression(i: number): ExpressionContext | null;
|
|
3649
3687
|
COMMA(): antlr.TerminalNode[];
|
|
3650
3688
|
COMMA(i: number): antlr.TerminalNode | null;
|
|
3651
3689
|
get ruleIndex(): number;
|
|
@@ -3735,7 +3773,7 @@ export declare class PathSpecificationContext extends antlr.ParserRuleContext {
|
|
|
3735
3773
|
accept<Result>(visitor: ImpalaSqlParserVisitor<Result>): Result | null;
|
|
3736
3774
|
}
|
|
3737
3775
|
export declare class PrivilegeContext extends antlr.ParserRuleContext {
|
|
3738
|
-
|
|
3776
|
+
_name?: IdentifierContext;
|
|
3739
3777
|
constructor(parent: antlr.ParserRuleContext | null, invokingState: number);
|
|
3740
3778
|
KW_ALL(): antlr.TerminalNode | null;
|
|
3741
3779
|
KW_ALTER(): antlr.TerminalNode | null;
|