Skip to content

Instantly share code, notes, and snippets.

@VikramVasudevan
Created January 1, 2020 07:43
Show Gist options
  • Save VikramVasudevan/b943f7d76cd34387a62beb0c422121bd to your computer and use it in GitHub Desktop.
Save VikramVasudevan/b943f7d76cd34387a62beb0c422121bd to your computer and use it in GitHub Desktop.
SELECT REPLACE (
REPLACE (trigger_sql,
'{INSERT_SET_CLAUSE}',
insert_column_list || ';'),
'{UPDATE_SET_CLAUSE}',
update_column_list || ';')
trigger_sql
FROM table_agg_stg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment