Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support aws_sns_topic property in Snowflake #243

Merged
merged 5 commits into from
Apr 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions macros/plugins/snowflake/create_external_table.sql
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@
{% if external.auto_refresh in (true, false) -%}
auto_refresh = {{external.auto_refresh}}
{%- endif %}
{% if external.aws_sns_topic -%}
aws_sns_topic = '{{external.aws_sns_topic}}'
{%- endif %}
{% if external.table_format | lower == "delta" %}
refresh_on_create = false
{% endif %}
Expand Down
10 changes: 9 additions & 1 deletion sample_sources/snowflake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,12 @@ sources:
- name: id
description: this is an id
- name: name
description: and this is a name
description: and this is a name

- name: aws_sns_refresh_tbl
description: "External table using AWS SNS for auto-refresh"
external:
location: "@stage" # reference an existing external stage
file_format: "( type = csv )"
# auto_refresh is assumed, setting to false is not supported
aws_sns_topic: "arn:aws:sns:us-east-1:123456789012:my_topic" # SNS topic ARN
Loading