[
https://issues.apache.org/jira/browse/HIVE-16609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Dai reassigned HIVE-16609:
---------------------------------
> col='__HIVE_DEFAULT_PARTITION__' condition in select statement may produce
> wrong result
> ---------------------------------------------------------------------------------------
>
> Key: HIVE-16609
> URL: https://issues.apache.org/jira/browse/HIVE-16609
> Project: Hive
> Issue Type: Bug
> Components: Metastore
> Reporter: Daniel Dai
> Assignee: Daniel Dai
>
> A variation of drop_partitions_filter4.q produces wrong result:
> {code}
> create table ptestfilter (a string, b int) partitioned by (c string, d int);
> INSERT OVERWRITE TABLE ptestfilter PARTITION (c,d) select 'Col1', 1, null,
> null;
> INSERT OVERWRITE TABLE ptestfilter PARTITION (c,d) select 'Col2', 2, null, 2;
> INSERT OVERWRITE TABLE ptestfilter PARTITION (c,d) select 'Col3', 3,
> 'Uganda', null;
> select * from ptestfilter where c='__HIVE_DEFAULT_PARTITION__' or
> lower(c)='a';
> {code}
> The "select" statement does not produce the rows containing
> "__HIVE_DEFAULT_PARTITION__".
> Note "select * from ptestfilter where c is null or lower(c)='a';" works fine.
> In the query, c is a non-string partition column, we need another condition
> containing a udf so the condition is not recognized by
> PartFilterExprUtil.makeExpressionTree in ObjectStore. HIVE-11208/HIVE-15923
> is addressing a similar issue in drop partition, however, select is not
> covered.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)