[
https://issues.apache.org/jira/browse/SPARK-14172?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15350704#comment-15350704
]
Jiang Xingbo commented on SPARK-14172:
--------------------------------------
Yes you are right. I thought the deterministic part can always be PPDed safely
but it was not, in fact, the order of each part should also be considered. For
example:
{code:sql}rand() < 0.01 AND partition_col = 'some_value'{code} should not be
PPDed, but
{code:sql}partition_col = 'some_value' AND rand() < 0.01{code} still could be.
Thank you for your kindly reply!
> Hive table partition predicate not passed down correctly
> --------------------------------------------------------
>
> Key: SPARK-14172
> URL: https://issues.apache.org/jira/browse/SPARK-14172
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 1.6.1
> Reporter: Yingji Zhang
> Priority: Critical
>
> When the hive sql contains nondeterministic fields, spark plan will not push
> down the partition predicate to the HiveTableScan. For example:
> {code}
> -- consider following query which uses a random function to sample rows
> SELECT *
> FROM table_a
> WHERE partition_col = 'some_value'
> AND rand() < 0.01;
> {code}
> The spark plan will not push down the partition predicate to HiveTableScan
> which ends up scanning all partitions data from the table.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]