Welcome to the Cloudera Community

Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Who agreed with this topic

Query the hive metastore from impala

avatar
Explorer

For reasons I won't go into we have a need to provide information about the partitions in a table.

The following statement provides that info:

show partitions database.table;

However that doesn't make the returned dataset queryable.

What I want to do is put a view over the top of that information so it can be filtered/aggregated. Essentially I want to do this:

CREATE VIEW database.<table>_partitions 
as
show partitions database.table;

but I can't do that of course.

Is there a way to query the hive metastore in order to get this information?

Who agreed with this topic