Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
313 views
in Technique[技术] by (71.8m points)

How to truncate a snowflake table before loading it from AWS Glue

We are having some AWS Glue jobs , which are reading the data from Amazon S3 Locations and writing data into snowflake tables. We want to truncate the tables before each load. could someone helping me to do this.

Thanks, Ram.

question from:https://stackoverflow.com/questions/65937187/how-to-truncate-a-snowflake-table-before-loading-it-from-aws-glue

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Simply run truncate query

truncate table if exists table_name;

If what you are asking is how to create an ETL that incorporate the AWS Glue job with running query on Snowflake that is depended on the ETL tool that you use and what it can do. That however is a question for the ETL tool that you are using. i can suggest using Apache Airflow which can schedule Glue jobs and run Snowflake queries.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...