hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chaoyu Tang" <>
Subject Re: Review Request 27737: HIVE-8784:Querying partition does not work with JDO enabled against PostgreSQL
Date Mon, 10 Nov 2014 16:58:50 GMT

This is an automatically generated e-mail. To reply, visit:

(Updated Nov. 10, 2014, 4:58 p.m.)

Review request for hive.


Add more test cases using ORM and sqldirect.

Repository: hive-git


Querying a partition in PostgreSQL fails when using JDO (with
It is because the JDO pushdown filter generated for a query having inequality/between partition
predicate uses DN indexOf function which is not working properly with postgresql. Hive (see
generateJDOFilterOverPartitions in org.apache.hadoop.hive.metastore.parser.ExpressTree) uses
some DN string functions (substring, indexOf) to get the value for a partitionKey. Actually
there is a straightforward way (as implemented in this patch) to get it which in addition
avoids the DN indexOf issue with postgresql.

Diffs (updated)

  metastore/src/java/org/apache/hadoop/hive/metastore/parser/ b8d1afc57642d9b07cb6b3b48c4ac9bcf6c76704

  ql/src/test/queries/clientpositive/partition_multilevels.q PRE-CREATION 
  ql/src/test/results/clientpositive/partition_multilevels.q.out PRE-CREATION 



The test cases provided in this patch have been tested against various DB including Derby,
Mysql and PostgreSQL etc.


Chaoyu Tang

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message