maropu commented on a change in pull request #29999:
URL: https://github.com/apache/spark/pull/29999#discussion_r502782869
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/parser/AstBuilder.scala
##########
@@ -1408,7 +1408,13 @@ class AstBuilder(conf: SQLConf) extends
SqlBaseBaseVisitor[AnyRef] with Logging
case Some(SqlBaseParser.ANY) | Some(SqlBaseParser.SOME) =>
getLikeQuantifierExprs(ctx.expression).reduceLeft(Or)
case Some(SqlBaseParser.ALL) =>
- getLikeQuantifierExprs(ctx.expression).reduceLeft(And)
+ if (ctx.expression.isEmpty) {
+ throw new ParseException("Expected something between '(' and
')'.", ctx)
+ }
+ ctx.NOT match {
+ case null => LikeAll(e, ctx.expression.asScala.map(expression))
Review comment:
Does this change disable the datasource pushdown for LIKE (e.g.,
StartsWith, EndsWith)? If so, we possibly get performance regression when
reading datasources, I think.
----------------------------------------------------------------
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]