-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-12231][SQL]create a combineFilters' projection when we call buildPartitionedTableScan #10299
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We use use an AttributeSet anytime we are dealing with AttributeReference objects.
|
ok to test |
|
Test build #47682 has finished for PR 10299 at commit
|
|
Hello Michael: I fixed the scala style issue, can you help re-run the test? Thanks. |
|
ok to test |
|
Test build #47690 has finished for PR 10299 at commit
|
|
Test build #47691 has finished for PR 10299 at commit
|
|
The failure is because of the changed project, will submit an updated patch tomorrow. |
|
I will create a new PR. |
…uildPartitionedTableScan Hello Michael & All: We have some issues to submit the new codes in the other PR(apache#10299), so we closed that PR and open this one with the fix. The reason for the previous failure is that the projection for the scan when there is a filter that is not pushed down (the "left-over" filter) could be different, in elements or ordering, from the original projection. With this new codes, the approach to solve this problem is: Insert a new Project if the "left-over" filter is nonempty and (the original projection is not empty and the projection for the scan has more than one elements which could otherwise cause different ordering in projection). We create 3 test cases to cover the otherwise failure cases. Author: Kevin Yu <[email protected]> Closes apache#10388 from kevinyu98/spark-12231.
…uildPartitionedTableScan Hello Michael & All: We have some issues to submit the new codes in the other PR(#10299), so we closed that PR and open this one with the fix. The reason for the previous failure is that the projection for the scan when there is a filter that is not pushed down (the "left-over" filter) could be different, in elements or ordering, from the original projection. With this new codes, the approach to solve this problem is: Insert a new Project if the "left-over" filter is nonempty and (the original projection is not empty and the projection for the scan has more than one elements which could otherwise cause different ordering in projection). We create 3 test cases to cover the otherwise failure cases. Author: Kevin Yu <[email protected]> Closes #10388 from kevinyu98/spark-12231. (cherry picked from commit fd50df4) Signed-off-by: Cheng Lian <[email protected]>
Hello Michael & All: Here I am submitting another approach to solve this problem. Can you verify ?
I think the problem is related to change from spark-10829,
before that PR change, the projects and filters are done inside buildPartitionedTableScan.
With that PR change, the filter expression divide to 3 parts, the filter left outside of the scan (combineFilters ) needs a different projection.
So the fix is to create a combine projection for the outside filter and beyond.
Thanks for your comments.