From dbf807639eb611b6965cf9d58b8867ca76849035 Mon Sep 17 00:00:00 2001 From: Joaquin Ossa Date: Fri, 3 Jan 2025 12:00:14 +0100 Subject: [PATCH] fixing copy paste --- .../intermediate/cross/int_deals_consolidation.sql | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/models/intermediate/cross/int_deals_consolidation.sql b/models/intermediate/cross/int_deals_consolidation.sql index e75f6e0..48ba62e 100644 --- a/models/intermediate/cross/int_deals_consolidation.sql +++ b/models/intermediate/cross/int_deals_consolidation.sql @@ -5,7 +5,7 @@ with core_deal_counts as ( select id_deal, count(distinct company_name) as core_company_name_count - from intermediate.int_core__unified_user + from int_core__unified_user where id_deal is not null group by id_deal ), @@ -18,7 +18,7 @@ with row_number() over ( partition by u.id_deal order by u.company_name ) as row_num - from intermediate.int_core__unified_user u + from int_core__unified_user u left join core_deal_counts c on u.id_deal = c.id_deal where u.id_deal is not null ), @@ -30,7 +30,7 @@ with hubspot_deal_counts as ( select id_deal, count(distinct deal_name) as hubspot_deal_name_count - from intermediate.int_hubspot__deal + from int_hubspot__deal where id_deal is not null group by id_deal ), @@ -41,7 +41,7 @@ with h.deal_name as hubspot_deal_name, c.hubspot_deal_name_count, row_number() over (partition by h.id_deal order by h.deal_name) as row_num - from intermediate.int_hubspot__deal h + from int_hubspot__deal h left join hubspot_deal_counts c on h.id_deal = c.id_deal where h.id_deal is not null ), @@ -53,7 +53,7 @@ with xero_contact_counts as ( select id_deal, count(distinct contact_name) as xero_contact_name_count - from intermediate.int_xero__contacts + from int_xero__contacts where id_deal is not null group by id_deal ), @@ -66,7 +66,7 @@ with row_number() over ( partition by x.id_deal order by x.contact_name ) as row_num - from intermediate.int_xero__contacts x + from int_xero__contacts x left join xero_contact_counts c on x.id_deal = c.id_deal where x.id_deal is not null ),