问题
I am trying to change a column name in an AWS Athena table.
From old_name
to new_name
.
Normal DDL commands does not affect the table (They cannot be executed).
Is It possible to change a column name without deleting and re-creating the table from scratch ?
回答1:
I was mistaken, Athena uses HIVE DDL
syntax so the correct command is :
ALTER TABLE %%table-name%% CHANGE %%old-column-name%% %%new-column-name%%<string>;
I based my answer on a hive
related question.
回答2:
You can find more about supported and unsupported DDLs here
来源:https://stackoverflow.com/questions/47418607/aws-athena-rename-column-name