THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
- The list of dependent partitions are materialized and stored in the metastore, and use that for querying.
A query like 'select .. from Tdependent where ds = 1' gets transformed to 'select .. from (select * from T where ((ds = 1 and hr = 1) or (ds = 1 and hr = 2) .... or (ds=1 and hr=24))'
Can put a lot of load on the query layer.
- The list of dependent partitions are materialized and stored in the metastore, and use that for querying.
= Final Proposal =
Instead of enhancing external tables to solve a convoluted usecase, create a new type of tables - dependent tables. The reason for the existence of external tables is to point to some existing data.
== Dependent Tables ==
Create a table which explicitly depends on another table. Consider the following scenario for the first use case mentioned:
<code>
create table T (key string, value string) partitioned by (ds string, hr string);
</code>