cloud-fan commented on code in PR #40565:
URL: https://github.com/apache/spark/pull/40565#discussion_r1151378459
##########
sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBaseParser.g4:
##########
@@ -993,14 +993,34 @@ colPosition
: position=FIRST | position=AFTER afterCol=errorCapturingIdentifier
;
+type
+ : BOOLEAN
+ | TINYINT | BYTE
+ | SMALLINT | SHORT
+ | INT | INTEGER
+ | BIGINT | LONG
+ | FLOAT | REAL
+ | DOUBLE
+ | DATE
+ | TIMESTAMP | TIMESTAMP_NTZ | TIMESTAMP_LTZ
+ | STRING
+ | CHARACTER | CHAR
+ | VARCHAR
+ | BINARY
+ | DECIMAL | DEC | NUMERIC
+ | VOID
+ | INTERVAL
+ | ARRAY | STRUCT | MAP
+ ;
Review Comment:
shall we still allow identifier? then we can keep the previous nice error
message for supported type string.
##########
sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBaseParser.g4:
##########
@@ -993,14 +993,34 @@ colPosition
: position=FIRST | position=AFTER afterCol=errorCapturingIdentifier
;
+type
+ : BOOLEAN
+ | TINYINT | BYTE
+ | SMALLINT | SHORT
+ | INT | INTEGER
+ | BIGINT | LONG
+ | FLOAT | REAL
+ | DOUBLE
+ | DATE
+ | TIMESTAMP | TIMESTAMP_NTZ | TIMESTAMP_LTZ
+ | STRING
+ | CHARACTER | CHAR
+ | VARCHAR
+ | BINARY
+ | DECIMAL | DEC | NUMERIC
+ | VOID
+ | INTERVAL
+ | ARRAY | STRUCT | MAP
+ ;
Review Comment:
shall we still allow identifier? then we can keep the previous nice error
message for unsupported type string.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]