[ 
https://issues.apache.org/jira/browse/HIVE-17956?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16234488#comment-16234488
 ] 

Micah Whitacre commented on HIVE-17956:
---------------------------------------

Actually that would be very useful.  I had found that JIRA but hadn't make the 
connection regarding sort order and the limit.  I think this would help to 
achieve what we are after.  I'm curious about the sort order when multiple 
partition keys might be required.

> Retrieve "latest" partition from Hive Metastore
> -----------------------------------------------
>
>                 Key: HIVE-17956
>                 URL: https://issues.apache.org/jira/browse/HIVE-17956
>             Project: Hive
>          Issue Type: New Feature
>          Components: Metastore
>            Reporter: Micah Whitacre
>
> We are trying to utilize the Hive Metastore for our processing needs, 
> specifically focusing on consuming through the HCatalog APIs.  One use case 
> we have is that we want to consume the "latest" partition.  In researching 
> there are a number of posts[1][2] that talk about using queries through Hive 
> Server2 to find that information.  It would be more ideal if this was a first 
> class API offered from the Hive Metastore without requiring a query to be 
> executed.
> The other option would be to retrieve all of the partitions and sort client 
> side.  There is a concern about the efficiency and memory requirements of 
> this especially without the "iterator" concept implemented from HIVE-7195.
> [1] - 
> https://community.hortonworks.com/questions/85330/how-to-optimize-hive-access-to-the-latest-partitio.html
> [2] - 
> https://stackoverflow.com/questions/36095790/how-to-find-the-most-recent-partition-in-hive-table



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to