Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

ALTER TABLE RECOVER PARTITIONS not working

Highlighted

ALTER TABLE RECOVER PARTITIONS not working

New Contributor

Hi,

 

When I run an ALTER TABLE RECOVER PARTITIONS, my Impala table is not getting updated with the most recent data. All the parquet files are in the proper directory. 

 

However, when I run a REFRESH TABLE, the table gets updated with the new data.

 

Why is the ALTER TABLE RECOVER PARTITIONS command not working in this case, but the REFRESH TABLE does?

 

Thank you!

1 REPLY 1
Highlighted

Re: ALTER TABLE RECOVER PARTITIONS not working

Cloudera Employee

It depends on how you are updating your partitions. Are you creating completely new partitions, or adding files to existing partitions? ALTER TABLE RECOVER PARTITIONS is specifically used for adding newly created partition directories to a partitioned table - https://impala.apache.org/docs/build/html/topics/impala_alter_table.html

Don't have an account?
Coming from Hortonworks? Activate your account here