From 13b671b09450629270fcff21372875bd330fd38e Mon Sep 17 00:00:00 2001 From: Doug Beatty Date: Fri, 26 Jan 2024 17:13:26 -0700 Subject: [PATCH 1/2] Compare contract data types prior to creating the DDL with data types and constraints --- dbt/include/redshift/macros/adapters.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dbt/include/redshift/macros/adapters.sql b/dbt/include/redshift/macros/adapters.sql index 5da047f58..3416221a5 100644 --- a/dbt/include/redshift/macros/adapters.sql +++ b/dbt/include/redshift/macros/adapters.sql @@ -48,8 +48,8 @@ create {% if temporary -%}temporary{%- endif %} table {{ relation.include(database=(not temporary), schema=(not temporary)) }} - {{ get_table_columns_and_constraints() }} {{ get_assert_columns_equivalent(sql) }} + {{ get_table_columns_and_constraints() }} {%- set sql = get_select_subquery(sql) %} {% if backup == false -%}backup no{%- endif %} {{ dist(_dist) }} From ba7c72038fd263811a2368526211bc4511315c25 Mon Sep 17 00:00:00 2001 From: Doug Beatty Date: Fri, 26 Jan 2024 17:14:23 -0700 Subject: [PATCH 2/2] Changelog entry --- .changes/unreleased/Fixes-20240126-171353.yaml | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .changes/unreleased/Fixes-20240126-171353.yaml diff --git a/.changes/unreleased/Fixes-20240126-171353.yaml b/.changes/unreleased/Fixes-20240126-171353.yaml new file mode 100644 index 000000000..6be4c9dd9 --- /dev/null +++ b/.changes/unreleased/Fixes-20240126-171353.yaml @@ -0,0 +1,6 @@ +kind: Fixes +body: Compare contract data types prior to creating the DDL with data types and constraints +time: 2024-01-26T17:13:53.430072-07:00 +custom: + Author: dbeatty10 + Issue: "707"