Github user smola commented on a diff in the pull request:

    https://github.com/apache/spark/pull/6326#discussion_r32732289
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/SqlParser.scala ---
    @@ -228,7 +228,12 @@ class SqlParser extends AbstractSparkSQLParser with 
DataTypeParser {
         andExpression * (OR ^^^ { (e1: Expression, e2: Expression) => Or(e1, 
e2) })
     
       protected lazy val andExpression: Parser[Expression] =
    -    comparisonExpression * (AND ^^^ { (e1: Expression, e2: Expression) => 
And(e1, e2) })
    +    booleanFactor * (AND ^^^ { (e1: Expression, e2: Expression) => And(e1, 
e2) })
    --- End diff --
    
    @chenghao-intel Not sure how. Adding the NOT clause in the expression rule 
would break precedence rules. Also, binding expression -> orExpression -> 
andExpression -> booleanFactor -> comparison is pretty much they way it is 
expressed in the grammars for standard SQL.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to