Github user gatorsmile commented on a diff in the pull request:
https://github.com/apache/spark/pull/21331#discussion_r190062760
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Canonicalize.scala
---
@@ -85,6 +87,10 @@ object Canonicalize {
case Not(GreaterThanOrEqual(l, r)) => LessThan(l, r)
case Not(LessThanOrEqual(l, r)) => GreaterThan(l, r)
+ // order the list in the In operator
+ case In(value, list) =>
+ In(value, list.sortBy(_.semanticHash()))
--- End diff --
A few general suggestions.
- We need to add test cases when we want to cover the extra cases.
- Update the comments in the description when we add new code
- Try our best to make the code simple.
- Find the best test suite when we add a new test. If unable to find a good
one, create a new test suite.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]