5

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 ?

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
C'estLaVie
  • 263
  • 1
  • 3
  • 9

2 Answers2

5

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.

C'estLaVie
  • 263
  • 1
  • 3
  • 9
2

You can find more about supported and unsupported DDLs here