You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2020/08/07 03:26:42 UTC
[GitHub] [incubator-pinot] mayankshriv commented on a change in pull request #5825: Enhance sql parser for having and post-aggregation
mayankshriv commented on a change in pull request #5825:
URL: https://github.com/apache/incubator-pinot/pull/5825#discussion_r466798962
##########
File path: pinot-common/src/main/java/org/apache/pinot/sql/parsers/CalciteSqlParser.java
##########
@@ -74,6 +74,11 @@
* non-alphanumeric characters. */
private static final Lex PINOT_LEX = Lex.MYSQL_ANSI;
+ // BABEL is a very liberal conformance value that allows anything supported by any dialect
+ private static final SqlParser.Config PARSER_CONFIG =
+ SqlParser.configBuilder().setLex(PINOT_LEX).setConformance(SqlConformanceEnum.BABEL)
Review comment:
@npawar I remember you had to relax the SQL parser to accept certain syntax. Was it Babel, or something else?
##########
File path: pinot-common/src/main/java/org/apache/pinot/sql/parsers/CalciteSqlParser.java
##########
@@ -397,7 +403,8 @@ private static void rewriteNonAggregationGroupByToDistinct(PinotQuery pinotQuery
pinotQuery.setGroupByList(Collections.emptyList());
} else {
selectIdentifiers.removeAll(groupByIdentifiers);
- throw new SqlCompilationException(String.format("For non-aggregation group by query, all the identifiers in select clause should be in groupBys. Found identifier: %s",
+ throw new SqlCompilationException(String.format(
+ "For non-aggregation group by query, all the identifiers in select clause should be in groupBys. Found identifier: %s",
Review comment:
@siddharthteotia, fyi, does this break any of your use cases for PQL -> SQL migration?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org