[
https://issues.apache.org/jira/browse/SPARK-30123?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Dongjoon Hyun updated SPARK-30123:
----------------------------------
Affects Version/s: (was: 3.0.0)
3.1.0
> PartitionPruning should consider more case
> ------------------------------------------
>
> Key: SPARK-30123
> URL: https://issues.apache.org/jira/browse/SPARK-30123
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 3.1.0
> Reporter: deshanxiao
> Priority: Major
>
> If left has partitionScan and right has PruningFilter but hasBenefit is
> false. The right will never be added a SubQuery.
> {code:java}
> var partScan = getPartitionTableScan(l, left)
> if (partScan.isDefined && canPruneLeft(joinType) &&
> hasPartitionPruningFilter(right)) {
> val hasBenefit = pruningHasBenefit(l, partScan.get, r, right)
> newLeft = insertPredicate(l, newLeft, r, right, rightKeys,
> hasBenefit)
> } else {
> partScan = getPartitionTableScan(r, right)
> if (partScan.isDefined && canPruneRight(joinType) &&
> hasPartitionPruningFilter(left) ) {
> val hasBenefit = pruningHasBenefit(r, partScan.get, l, left)
> newRight = insertPredicate(r, newRight, l, left, leftKeys,
> hasBenefit)
> }
> }
> case _ =>
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]