Reputation: 303
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 ?
Upvotes: 5
Views: 11347
Reputation: 303
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.
Upvotes: 6
Reputation: 101
You can find more about supported and unsupported DDLs here
Upvotes: 2