How to Replace/Overwrite only certain values in Snowflake Table?
I have a Snowflake SQL command in the form of: CREATE TASK REPLACE_CERTAIN_ROWS WAREHOUSE=<MY_WAREHOUSE> SCHEDULE='USING CRON 0 5,17 * * * UTC' AS insert overwrite into <MY_SCHEMA>.<MY_TABLE>(FIELD1,FIELD2) <MY_SQL> And my table looks like: FIELD1|FIELD2 ABC,REPLACE DEF,REPLACE GHI,DONTREPLACE JKL,DONTREPLACE Instead of replacing the entire table how can I alter my Snowflake to only overwrite the FIELD2='REPLACE' rows? Do I have to first have a command that deletes these rows or is there a way to do it more instantaneously? I know I can only execute one command per Snowflake task so would like
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.