dt-sql-parser 4.1.2-beta.0 → 4.2.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 +5 -5
- package/dist/lib/flink/FlinkSqlLexer.js +1991 -1992
- package/dist/lib/flink/FlinkSqlParser.d.ts +240 -230
- package/dist/lib/flink/FlinkSqlParser.js +3036 -2978
- package/dist/lib/flink/FlinkSqlParserListener.d.ts +81 -70
- package/dist/lib/flink/FlinkSqlParserVisitor.d.ts +49 -42
- package/dist/lib/hive/HiveSqlParser.d.ts +251 -231
- package/dist/lib/hive/HiveSqlParser.js +6264 -5674
- package/dist/lib/hive/HiveSqlParserListener.d.ts +32 -10
- package/dist/lib/hive/HiveSqlParserVisitor.d.ts +20 -6
- package/dist/lib/impala/ImpalaSqlLexer.d.ts +2 -2
- package/dist/lib/impala/ImpalaSqlLexer.js +587 -588
- package/dist/lib/impala/ImpalaSqlParser.d.ts +151 -113
- package/dist/lib/impala/ImpalaSqlParser.js +3464 -3250
- package/dist/lib/impala/ImpalaSqlParserListener.d.ts +49 -5
- package/dist/lib/impala/ImpalaSqlParserVisitor.d.ts +31 -3
- package/dist/lib/mysql/MySqlLexer.d.ts +2 -2
- package/dist/lib/mysql/MySqlLexer.js +3515 -3516
- package/dist/lib/mysql/MySqlParser.d.ts +138 -138
- package/dist/lib/mysql/MySqlParser.js +511 -511
- package/dist/lib/mysql/MySqlParserListener.d.ts +105 -105
- package/dist/lib/mysql/MySqlParserVisitor.d.ts +63 -63
- package/dist/lib/postgresql/PostgreSqlLexer.d.ts +14 -15
- package/dist/lib/postgresql/PostgreSqlLexer.js +2077 -2092
- package/dist/lib/postgresql/PostgreSqlParser.d.ts +2860 -2980
- package/dist/lib/postgresql/PostgreSqlParser.js +20155 -20660
- package/dist/lib/postgresql/PostgreSqlParserListener.d.ts +2110 -2181
- package/dist/lib/postgresql/PostgreSqlParserVisitor.d.ts +1261 -1301
- package/dist/lib/spark/SparkSqlLexer.d.ts +2 -2
- package/dist/lib/spark/SparkSqlLexer.js +949 -950
- package/dist/lib/spark/SparkSqlParser.d.ts +413 -645
- package/dist/lib/spark/SparkSqlParser.js +6840 -8200
- package/dist/lib/spark/SparkSqlParserListener.d.ts +68 -356
- package/dist/lib/spark/SparkSqlParserVisitor.d.ts +42 -225
- package/dist/lib/trino/TrinoSqlLexer.d.ts +2 -2
- package/dist/lib/trino/TrinoSqlLexer.js +319 -321
- package/dist/lib/trino/TrinoSqlListener.d.ts +67 -23
- package/dist/lib/trino/TrinoSqlParser.d.ts +210 -181
- package/dist/lib/trino/TrinoSqlParser.js +4854 -4695
- package/dist/lib/trino/TrinoSqlVisitor.d.ts +42 -14
- 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 +25 -0
- package/dist/parser/common/types.js +7 -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 +22 -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 +51 -42
- package/dist/parser/postgresql/postgreEntityCollector.d.ts +5 -5
- package/dist/parser/postgresql/postgreEntityCollector.js +7 -7
- package/dist/parser/postgresql/postgreErrorListener.js +36 -30
- 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
|
@@ -3,7 +3,7 @@ import { ProgramContext } from "./HiveSqlParser.js";
|
|
|
3
3
|
import { StatementContext } from "./HiveSqlParser.js";
|
|
4
4
|
import { ExplainStatementContext } from "./HiveSqlParser.js";
|
|
5
5
|
import { ExplainOptionContext } from "./HiveSqlParser.js";
|
|
6
|
-
import {
|
|
6
|
+
import { VectorizationDetailContext } from "./HiveSqlParser.js";
|
|
7
7
|
import { ExecStatementContext } from "./HiveSqlParser.js";
|
|
8
8
|
import { LoadStatementContext } from "./HiveSqlParser.js";
|
|
9
9
|
import { ReplicationClauseContext } from "./HiveSqlParser.js";
|
|
@@ -59,7 +59,7 @@ import { PrivilegeObjectContext } from "./HiveSqlParser.js";
|
|
|
59
59
|
import { PrivObjectContext } from "./HiveSqlParser.js";
|
|
60
60
|
import { PrivObjectColsContext } from "./HiveSqlParser.js";
|
|
61
61
|
import { PrivilegeListContext } from "./HiveSqlParser.js";
|
|
62
|
-
import {
|
|
62
|
+
import { PrivilegeDefContext } from "./HiveSqlParser.js";
|
|
63
63
|
import { PrivilegeTypeContext } from "./HiveSqlParser.js";
|
|
64
64
|
import { PrincipalSpecificationContext } from "./HiveSqlParser.js";
|
|
65
65
|
import { PrincipalNameContext } from "./HiveSqlParser.js";
|
|
@@ -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";
|
|
@@ -393,15 +395,15 @@ export declare class HiveSqlParserListener implements ParseTreeListener {
|
|
|
393
395
|
*/
|
|
394
396
|
exitExplainOption?: (ctx: ExplainOptionContext) => void;
|
|
395
397
|
/**
|
|
396
|
-
* Enter a parse tree produced by `HiveSqlParser.
|
|
398
|
+
* Enter a parse tree produced by `HiveSqlParser.vectorizationDetail`.
|
|
397
399
|
* @param ctx the parse tree
|
|
398
400
|
*/
|
|
399
|
-
|
|
401
|
+
enterVectorizationDetail?: (ctx: VectorizationDetailContext) => void;
|
|
400
402
|
/**
|
|
401
|
-
* Exit a parse tree produced by `HiveSqlParser.
|
|
403
|
+
* Exit a parse tree produced by `HiveSqlParser.vectorizationDetail`.
|
|
402
404
|
* @param ctx the parse tree
|
|
403
405
|
*/
|
|
404
|
-
|
|
406
|
+
exitVectorizationDetail?: (ctx: VectorizationDetailContext) => void;
|
|
405
407
|
/**
|
|
406
408
|
* Enter a parse tree produced by `HiveSqlParser.execStatement`.
|
|
407
409
|
* @param ctx the parse tree
|
|
@@ -953,15 +955,15 @@ export declare class HiveSqlParserListener implements ParseTreeListener {
|
|
|
953
955
|
*/
|
|
954
956
|
exitPrivilegeList?: (ctx: PrivilegeListContext) => void;
|
|
955
957
|
/**
|
|
956
|
-
* Enter a parse tree produced by `HiveSqlParser.
|
|
958
|
+
* Enter a parse tree produced by `HiveSqlParser.privilegeDef`.
|
|
957
959
|
* @param ctx the parse tree
|
|
958
960
|
*/
|
|
959
|
-
|
|
961
|
+
enterPrivilegeDef?: (ctx: PrivilegeDefContext) => void;
|
|
960
962
|
/**
|
|
961
|
-
* Exit a parse tree produced by `HiveSqlParser.
|
|
963
|
+
* Exit a parse tree produced by `HiveSqlParser.privilegeDef`.
|
|
962
964
|
* @param ctx the parse tree
|
|
963
965
|
*/
|
|
964
|
-
|
|
966
|
+
exitPrivilegeDef?: (ctx: PrivilegeDefContext) => void;
|
|
965
967
|
/**
|
|
966
968
|
* Enter a parse tree produced by `HiveSqlParser.privilegeType`.
|
|
967
969
|
* @param ctx the parse tree
|
|
@@ -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
|
|
@@ -3,7 +3,7 @@ import { ProgramContext } from "./HiveSqlParser.js";
|
|
|
3
3
|
import { StatementContext } from "./HiveSqlParser.js";
|
|
4
4
|
import { ExplainStatementContext } from "./HiveSqlParser.js";
|
|
5
5
|
import { ExplainOptionContext } from "./HiveSqlParser.js";
|
|
6
|
-
import {
|
|
6
|
+
import { VectorizationDetailContext } from "./HiveSqlParser.js";
|
|
7
7
|
import { ExecStatementContext } from "./HiveSqlParser.js";
|
|
8
8
|
import { LoadStatementContext } from "./HiveSqlParser.js";
|
|
9
9
|
import { ReplicationClauseContext } from "./HiveSqlParser.js";
|
|
@@ -59,7 +59,7 @@ import { PrivilegeObjectContext } from "./HiveSqlParser.js";
|
|
|
59
59
|
import { PrivObjectContext } from "./HiveSqlParser.js";
|
|
60
60
|
import { PrivObjectColsContext } from "./HiveSqlParser.js";
|
|
61
61
|
import { PrivilegeListContext } from "./HiveSqlParser.js";
|
|
62
|
-
import {
|
|
62
|
+
import { PrivilegeDefContext } from "./HiveSqlParser.js";
|
|
63
63
|
import { PrivilegeTypeContext } from "./HiveSqlParser.js";
|
|
64
64
|
import { PrincipalSpecificationContext } from "./HiveSqlParser.js";
|
|
65
65
|
import { PrincipalNameContext } from "./HiveSqlParser.js";
|
|
@@ -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";
|
|
@@ -380,11 +382,11 @@ export declare class HiveSqlParserVisitor<Result> extends AbstractParseTreeVisit
|
|
|
380
382
|
*/
|
|
381
383
|
visitExplainOption?: (ctx: ExplainOptionContext) => Result;
|
|
382
384
|
/**
|
|
383
|
-
* Visit a parse tree produced by `HiveSqlParser.
|
|
385
|
+
* Visit a parse tree produced by `HiveSqlParser.vectorizationDetail`.
|
|
384
386
|
* @param ctx the parse tree
|
|
385
387
|
* @return the visitor result
|
|
386
388
|
*/
|
|
387
|
-
|
|
389
|
+
visitVectorizationDetail?: (ctx: VectorizationDetailContext) => Result;
|
|
388
390
|
/**
|
|
389
391
|
* Visit a parse tree produced by `HiveSqlParser.execStatement`.
|
|
390
392
|
* @param ctx the parse tree
|
|
@@ -716,11 +718,11 @@ export declare class HiveSqlParserVisitor<Result> extends AbstractParseTreeVisit
|
|
|
716
718
|
*/
|
|
717
719
|
visitPrivilegeList?: (ctx: PrivilegeListContext) => Result;
|
|
718
720
|
/**
|
|
719
|
-
* Visit a parse tree produced by `HiveSqlParser.
|
|
721
|
+
* Visit a parse tree produced by `HiveSqlParser.privilegeDef`.
|
|
720
722
|
* @param ctx the parse tree
|
|
721
723
|
* @return the visitor result
|
|
722
724
|
*/
|
|
723
|
-
|
|
725
|
+
visitPrivilegeDef?: (ctx: PrivilegeDefContext) => Result;
|
|
724
726
|
/**
|
|
725
727
|
* Visit a parse tree produced by `HiveSqlParser.privilegeType`.
|
|
726
728
|
* @param ctx the parse tree
|
|
@@ -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)[];
|