diff --git a/dbt/include/snowflake/macros/adapters.sql b/dbt/include/snowflake/macros/adapters.sql index 3c93d41ad..61d923db4 100644 --- a/dbt/include/snowflake/macros/adapters.sql +++ b/dbt/include/snowflake/macros/adapters.sql @@ -205,10 +205,12 @@ {% macro snowflake__alter_relation_comment(relation, relation_comment) -%} {%- if relation.is_dynamic_table -%} {%- set relation_type = 'dynamic table' -%} + {%- elif relation.is_iceberg_format -%} + {%- set relation_type = 'iceberg table' -%} {%- else -%} {%- set relation_type = relation.type -%} {%- endif -%} - comment on {{ relation_type }} {{ relation.render() }} IS $${{ relation_comment | replace('$', '[$]') }}$$; + alter {{ relation_type }} {{ relation.render() }} set comment = $${{ relation_comment | replace('$', '[$]') }}$$; {% endmacro %}