cloud-fan commented on code in PR #60620:
URL: https://github.com/apache/spark/pull/60620#discussion_r4616563678
##########
sql/api/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBaseParser.g4:
##########
@@ -1308,7 +1308,7 @@ binByClause
(BIN_START AS binStartAlias=errorCapturingIdentifier)?
(BIN_END AS binEndAlias=errorCapturingIdentifier)?
(BIN_DISTRIBUTE_RATIO AS binRatioAlias=errorCapturingIdentifier)?
- RIGHT_PAREN (AS? tblAlias=errorCapturingIdentifier)?
+ RIGHT_PAREN (AS? tblAlias=strictIdentifier)?
Review Comment:
Keeping this PR to BIN BY and tracking PIVOT and UNPIVOT in SPARK-61976
works for me. Since that fix is deferred, please add a TODO at the pivotClause
and unpivotClause grammar rules that names SPARK-61976 and says their trailing
alias still takes a following join keyword, such as LEFT, as the alias in the
default keyword mode. Without it, readers of the grammar see BIN BY and GAP
FILL using strictIdentifier and PIVOT and UNPIVOT using
errorCapturingIdentifier, with nothing saying the difference is a known gap
rather than intended.
<!-- SPARK_DEV_REVIEW_REPLY
{"feedback_id":"inline:4603774126","thread_id":"inline:4603774126","verdict_sha256":"757367dcf31c9bff571aad46354c24c6fc7f3f0a4f15f60cc1c1a6931a72c158"}
-->
--
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]