From 5c9bbf78877ab9cb6088f07a4323a8d4eae4312c Mon Sep 17 00:00:00 2001 From: Jurri Gerretsen <62351599+jurrigerretsen@users.noreply.github.com> Date: Tue, 26 Mar 2024 13:45:05 +0100 Subject: [PATCH 1/2] =?UTF-8?q?=E2=9C=A8=20Support=20for=20additional=20v5?= =?UTF-8?q?=20columns?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- models/core/revenuecat_subscription_transactions.sql | 10 ++++++---- readme.md | 1 + 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/models/core/revenuecat_subscription_transactions.sql b/models/core/revenuecat_subscription_transactions.sql index aed3cfd..781c379 100644 --- a/models/core/revenuecat_subscription_transactions.sql +++ b/models/core/revenuecat_subscription_transactions.sql @@ -140,10 +140,12 @@ renamed as ( purchase_price_in_purchased_currency, product_display_name, product_duration, - --offer, - --offer_type, - --first_seen_time, - --auto_resume_time, + {%- if var('revenuecat_version') > 4 %} + offer, + offer_type, + first_seen_time, + auto_resume_time, + {%- endif %} {%- if var('revenuecat_custom_subscriber_attributes') %} {%- for key, value in var('revenuecat_custom_subscriber_attributes').items() %} diff --git a/readme.md b/readme.md index 1e387bb..6bd4986 100644 --- a/readme.md +++ b/readme.md @@ -22,6 +22,7 @@ vars: revenuecat_database: "source_db" revenuecat_schema: 'revenuecat' revenuecat_table: "data_export" + revenuecat_verson: 5 revenuecat_filter: "is_sandbox = false" revenuecat_custom_subscriber_attributes: {'my_value::text': 'my_column_name'} ``` From 4d3796a7297e0ed9f461e75f2f0eaa9c9d868158 Mon Sep 17 00:00:00 2001 From: Jurri Gerretsen <62351599+jurrigerretsen@users.noreply.github.com> Date: Tue, 26 Mar 2024 13:48:26 +0100 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=92=9A=20Add=20version=20number=20to?= =?UTF-8?q?=20integration=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- integration_tests/dbt_project.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/integration_tests/dbt_project.yml b/integration_tests/dbt_project.yml index 3adf8bb..2b6cffa 100644 --- a/integration_tests/dbt_project.yml +++ b/integration_tests/dbt_project.yml @@ -14,6 +14,7 @@ log-path: "logs" vars: tasman_dbt_revenuecat: revenuecat_table: "SEED_REVENUECAT_TRANSACTIONS_MOCKED" + revenuecat_version: 5 revenuecat_filter: "is_sandbox = false" revenuecat_custom_subscriber_attributes: "" revenuecat_mrr_test_seed: ""