Skip to content

Instantly share code, notes, and snippets.

View Lydon-01's full-sized avatar

Lydon Lydon-01

  • Cape Town, South Africa
View GitHub Profile
@Lydon-01
Lydon-01 / rename_table.py
Created February 21, 2019 05:12 — forked from dan-hook/rename_table.py
"Rename" an AWS Glue table by creating a new table
import boto3
database_name = "databse"
table_name = "prefix-dir_name"
new_table_name = "more_awesome_name"
client = boto3.client("glue")
response = client.get_table(DatabaseName=database_name, Name=table_name)
table_input = response["Table"]
table_input["Name"] = new_table_name