Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions reverse_engineering/grammars/HiveParser.g4
Original file line number Diff line number Diff line change
Expand Up @@ -1315,11 +1315,11 @@ tableConstraintType
;

constraintOptsCreate
: enableValidateSpecification relySpecification
: enableValidateSpecification? relySpecification
;

constraintOptsAlter
: enableValidateSpecification relySpecification
: enableValidateSpecification? relySpecification
;

columnNameColonType
Expand Down
2 changes: 1 addition & 1 deletion reverse_engineering/grammars/IdentifiersParser.g4
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ orderByClause
;

clusterByClause
: KW_CLUSTER KW_BY (LPAREN columnNameList RPAREN) | KW_AUTO | KW_NONE
: KW_CLUSTER KW_BY ( (LPAREN columnNameList RPAREN) | KW_AUTO | KW_NONE )
;

partitionByClause
Expand Down
5 changes: 4 additions & 1 deletion reverse_engineering/grammars/SqlBase.g4
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ createTableClauses
;

clusterBySpec
: CLUSTER BY ( '(' keyNameList ')' ) | AUTO | NONE
: CLUSTER BY ( '(' keyNameList ')' | AUTO | NONE )
;

tableProperties
Expand Down Expand Up @@ -962,6 +962,7 @@ constraintOptions
| DEFERRABLE
| INITIALLY DEFERRED
| NORELY
| RELY
;

columnConstraint
Expand Down Expand Up @@ -1437,6 +1438,7 @@ nonReserved
| INPATH
| INPUTFORMAT
| INSERT
| INTERSECT
| INTERVAL
| INTO
| IS
Expand Down Expand Up @@ -1859,6 +1861,7 @@ DEFERRABLE : D E F E R R A B L E;
INITIALLY : I N I T I A L L Y;
DEFERRED : D E F E R R E D;
NORELY : N O R E L Y;
RELY : R E L Y;
MATCH : M A T C H;
ACTION : A C T I O N;

Expand Down
6 changes: 1 addition & 5 deletions reverse_engineering/hqlToCollectionsVisitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -1694,11 +1694,7 @@ class Visitor extends HiveParserVisitor {
}

visitClusterByClause(ctx) {
const compositeClusteringKey = ctx
.columnNameList()
.getText()
.split(',')
.map(name => ({ name }));
const compositeClusteringKey = (ctx.columnNameList()?.getText() || '').split(',').map(name => ({ name }));

return {
compositeClusteringKey,
Expand Down
2 changes: 1 addition & 1 deletion reverse_engineering/parser/Hive/HiveParser.interp

Large diffs are not rendered by default.

6,264 changes: 3,121 additions & 3,143 deletions reverse_engineering/parser/Hive/HiveParser.js

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion reverse_engineering/parser/SQLBase/SqlBase.interp

Large diffs are not rendered by default.

113 changes: 57 additions & 56 deletions reverse_engineering/parser/SQLBase/SqlBase.tokens
Original file line number Diff line number Diff line change
Expand Up @@ -282,47 +282,48 @@ DEFERRABLE=281
INITIALLY=282
DEFERRED=283
NORELY=284
MATCH=285
ACTION=286
KW_GENERATED=287
KW_ALWAYS=288
KW_DEFAULT=289
KW_IDENTITY=290
KW_INCREMENT=291
EQ=292
NSEQ=293
NEQ=294
NEQJ=295
LT=296
LTE=297
GT=298
GTE=299
PLUS=300
MINUS=301
ASTERISK=302
SLASH=303
PERCENT=304
TILDE=305
AMPERSAND=306
PIPE=307
CONCAT_PIPE=308
HAT=309
STRING=310
BIGINT_LITERAL=311
SMALLINT_LITERAL=312
TINYINT_LITERAL=313
INTEGER_VALUE=314
EXPONENT_VALUE=315
DECIMAL_VALUE=316
FLOAT_LITERAL=317
DOUBLE_LITERAL=318
BIGDECIMAL_LITERAL=319
IDENTIFIER=320
BACKQUOTED_IDENTIFIER=321
SIMPLE_COMMENT=322
BRACKETED_COMMENT=323
WS=324
UNRECOGNIZED=325
RELY=285
MATCH=286
ACTION=287
KW_GENERATED=288
KW_ALWAYS=289
KW_DEFAULT=290
KW_IDENTITY=291
KW_INCREMENT=292
EQ=293
NSEQ=294
NEQ=295
NEQJ=296
LT=297
LTE=298
GT=299
GTE=300
PLUS=301
MINUS=302
ASTERISK=303
SLASH=304
PERCENT=305
TILDE=306
AMPERSAND=307
PIPE=308
CONCAT_PIPE=309
HAT=310
STRING=311
BIGINT_LITERAL=312
SMALLINT_LITERAL=313
TINYINT_LITERAL=314
INTEGER_VALUE=315
EXPONENT_VALUE=316
DECIMAL_VALUE=317
FLOAT_LITERAL=318
DOUBLE_LITERAL=319
BIGDECIMAL_LITERAL=320
IDENTIFIER=321
BACKQUOTED_IDENTIFIER=322
SIMPLE_COMMENT=323
BRACKETED_COMMENT=324
WS=325
UNRECOGNIZED=326
';'=1
'('=2
','=3
Expand All @@ -334,18 +335,18 @@ UNRECOGNIZED=325
'['=9
']'=10
':'=11
'<=>'=293
'<>'=294
'!='=295
'<'=296
'>'=298
'+'=300
'-'=301
'*'=302
'/'=303
'%'=304
'~'=305
'&'=306
'|'=307
'||'=308
'^'=309
'<=>'=294
'<>'=295
'!='=296
'<'=297
'>'=299
'+'=301
'-'=302
'*'=303
'/'=304
'%'=305
'~'=306
'&'=307
'|'=308
'||'=309
'^'=310
5 changes: 4 additions & 1 deletion reverse_engineering/parser/SQLBase/SqlBaseLexer.interp

Large diffs are not rendered by default.

Loading