Skip to content

Commit

Permalink
Bug/dynamic table alter on column syntax (dbt-labs#790)
Browse files Browse the repository at this point in the history
* bug/Dynamic-table-comment-on-syntax
* Add changelog
* Fix relation type
* Fix alter
* Update dynamic table comment alter statement
* update comment on syntax

---------

Co-authored-by: Pat Kearns <[email protected]>
Co-authored-by: Mike Alfare <[email protected]>
Co-authored-by: colin-rogers-dbt <[email protected]>
  • Loading branch information
4 people authored and philippe-boyd-maxa committed Nov 27, 2023
1 parent a63399c commit 6c684b4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .changes/unreleased/Fixes-20231002-144648.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
kind: Fixes
body: Fix the alter syntax on column for dynamic table
time: 2023-10-02T14:46:48.980242+13:00
custom:
Author: kaarthik108
Issue: "769"
2 changes: 1 addition & 1 deletion dbt/include/snowflake/macros/adapters.sql
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
{% macro snowflake__alter_column_comment(relation, column_dict) -%}
{% set existing_columns = adapter.get_columns_in_relation(relation) | map(attribute="name") | list %}
{% if relation.is_dynamic_table -%}
{% set relation_type = "dynamic table" %}
{% set relation_type = "table" %}
{% else -%}
{% set relation_type = relation.type %}
{% endif %}
Expand Down

0 comments on commit 6c684b4

Please sign in to comment.