You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Kokila N (Jira)" <ji...@apache.org> on 2023/10/09 05:22:00 UTC

[jira] [Created] (HIVE-27778) Alter table command gives error after computer stats is run with Impala

Kokila N created HIVE-27778:
-------------------------------

             Summary: Alter table command gives error after computer stats is run with Impala
                 Key: HIVE-27778
                 URL: https://issues.apache.org/jira/browse/HIVE-27778
             Project: Hive
          Issue Type: Bug
            Reporter: Kokila N


Hive partitioned table's column stats are stored on partition level which is in PART_COL_STATS in sys.

When "column stats <table_name>" query is run in Impala on a Hive partitioned table generates column stats on table level and is stored in TAB_COL_STATS.

So, Executing "Alter rename <old_table> to <new_table>" after impala compute stats throws error.
{code:java}
ERROR : Failed
org.apache.hadoop.hive.ql.metadata.HiveException: Unable to alter table. Cannot change stats state for a transactional table default.parqtest without providing the transactional write state for verification (new write ID 6, valid write IDs null; current state null; new state {} {code}
The column stats generated from impala needs to be deleted for alter command to work.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)