Renaming column name in Athena

0 votes
Normal DDL commands does not affect the table (They cannot be executed). I am trying to change a column name in an AWS Athena table old_name to new_name. Is It possible to change a column name without deleting and re-creating the table from scratch?

Can someone help?
Jan 17, 2019 in AWS by Anjali
• 2,950 points
6,017 views

1 answer to this question.

0 votes

You can use :-

ALTER TABLE %%table-name%% CHANGE %%old-column-name%% %%new-column-name%%<string>;

You can find more about supported and unsupported DDLs here.

Hope this helps

answered Jan 17, 2019 by julie

Related Questions In AWS

+3 votes
6 answers

Renaming files in S3

You can either use AWS CLI or ...READ MORE

answered Oct 16, 2018 in AWS by petter dj
30,999 views
0 votes
2 answers

How to skip headers when reading a CSV file in S3 and creating a table in AWS Athena?

Thanks for the answer. This should be clear ...READ MORE

answered Aug 14, 2019 in AWS by athenauserz
11,719 views
0 votes
1 answer

Pivot rows into columns in AWS Athena?

You can use the following method :- It ...READ MORE

answered Oct 29, 2018 in AWS by Priyaj
• 58,100 points
8,123 views
0 votes
1 answer

How to convert String to Date in Amazon Athena?

You can use date_parse. All you need ...READ MORE

answered Jan 16, 2019 in AWS by chandan
27,556 views
0 votes
1 answer
+1 vote
2 answers
0 votes
1 answer

How to Use hypen as key name in dynamo db mapper

It seems you cannot have a column ...READ MORE

answered Aug 22, 2018 in AWS by Priyaj
• 58,100 points
3,134 views
0 votes
1 answer

Is it possible to create view in Athena?

AWS Athena does not support creating any ...READ MORE

answered Jan 16, 2019 in AWS by Zullu
1,380 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP