You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Hong Shen (JIRA)" <ji...@apache.org> on 2015/06/17 09:20:01 UTC

[jira] [Updated] (SPARK-8403) Pruner partition won't effective when udf exit in sql predicates

     [ https://issues.apache.org/jira/browse/SPARK-8403?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hong Shen updated SPARK-8403:
-----------------------------
    Description: 
When udf exit in sql predicates, pruner partition won't effective.
Here is the sql,
{code}
select r.uin,r.vid,r.ctype,r.bakstr2,r.cmd from t_dw_qqlive_2090000026 r where r.cmd = 2 and (r.imp_date = 20150615 or and hour(r.itimestamp)>16)
{code}
When run on hive, it will only scan data in partition 20150615, but if run on spark sql, it will scan the whole table from t_dw_qqlive_2090000026.



  was:
When udf exit in sql predicates, pruner partition won't effective.
Here is the sql,
{code}
select r.uin,r.vid,r.ctype,r.bakstr2,r.cmd from t_dw_qqlive_2090000026 r where r.cmd = 2 and (r.imp_date = 20150615 or and hour(r.itimestamp)>16)
{code}
When run on hive, it will only scan data in partition 20150615, but if run on spark sql, it will scan the whole table fromt_dw_qqlive_2090000026.




> Pruner partition won't effective when udf exit in sql predicates
> ----------------------------------------------------------------
>
>                 Key: SPARK-8403
>                 URL: https://issues.apache.org/jira/browse/SPARK-8403
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>            Reporter: Hong Shen
>
> When udf exit in sql predicates, pruner partition won't effective.
> Here is the sql,
> {code}
> select r.uin,r.vid,r.ctype,r.bakstr2,r.cmd from t_dw_qqlive_2090000026 r where r.cmd = 2 and (r.imp_date = 20150615 or and hour(r.itimestamp)>16)
> {code}
> When run on hive, it will only scan data in partition 20150615, but if run on spark sql, it will scan the whole table from t_dw_qqlive_2090000026.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org