From 7d3d11ea7ff9f8ac80ab57843baf3daa29571094 Mon Sep 17 00:00:00 2001 From: Joaquin Date: Sat, 2 Nov 2024 18:32:38 +0100 Subject: [PATCH] modified names --- ..._monthly_check_in_attrib_guest_journeys.sql} | 4 ++-- ..._agg_mtd_check_in_attrib_guest_journeys.sql} | 4 ++-- ...ic_daily_check_in_attrib_guest_journeys.sql} | 0 ..._monthly_check_in_attrib_guest_journeys.sql} | 2 +- ...tric_mtd_check_in_attrib_guest_journeys.sql} | 2 +- models/intermediate/kpis/schema.yml | 17 +++++++---------- 6 files changed, 13 insertions(+), 16 deletions(-) rename models/intermediate/kpis/{int_kpis__aggregated_mtd_check_in_attributed_guest_journeys.sql => int_kpis__agg_monthly_check_in_attrib_guest_journeys.sql} (93%) rename models/intermediate/kpis/{int_kpis__aggregated_monthly_check_in_attributed_guest_journeys.sql => int_kpis__agg_mtd_check_in_attrib_guest_journeys.sql} (91%) rename models/intermediate/kpis/{int_kpis__metric_daily_check_in_attributed_guest_journeys.sql => int_kpis__metric_daily_check_in_attrib_guest_journeys.sql} (100%) rename models/intermediate/kpis/{int_kpis__metric_monthly_check_in_attributed_guest_journeys.sql => int_kpis__metric_monthly_check_in_attrib_guest_journeys.sql} (93%) rename models/intermediate/kpis/{int_kpis__metric_mtd_check_in_attributed_guest_journeys.sql => int_kpis__metric_mtd_check_in_attrib_guest_journeys.sql} (93%) diff --git a/models/intermediate/kpis/int_kpis__aggregated_mtd_check_in_attributed_guest_journeys.sql b/models/intermediate/kpis/int_kpis__agg_monthly_check_in_attrib_guest_journeys.sql similarity index 93% rename from models/intermediate/kpis/int_kpis__aggregated_mtd_check_in_attributed_guest_journeys.sql rename to models/intermediate/kpis/int_kpis__agg_monthly_check_in_attrib_guest_journeys.sql index c2df07a..58284ae 100644 --- a/models/intermediate/kpis/int_kpis__aggregated_mtd_check_in_attributed_guest_journeys.sql +++ b/models/intermediate/kpis/int_kpis__agg_monthly_check_in_attrib_guest_journeys.sql @@ -27,9 +27,9 @@ sum(created_guest_journeys) as created_guest_journeys, sum(started_guest_journeys) as started_guest_journeys, sum(completed_guest_journeys) as completed_guest_journeys - from {{ ref("int_kpis__metric_mtd_check_in_attributed_guest_journeys") }} + from {{ ref("int_kpis__metric_monthly_check_in_attrib_guest_journeys") }} group by 1, 2, 3, 4 {% if not loop.last %} union all {% endif %} -{% endfor %} \ No newline at end of file +{% endfor %} diff --git a/models/intermediate/kpis/int_kpis__aggregated_monthly_check_in_attributed_guest_journeys.sql b/models/intermediate/kpis/int_kpis__agg_mtd_check_in_attrib_guest_journeys.sql similarity index 91% rename from models/intermediate/kpis/int_kpis__aggregated_monthly_check_in_attributed_guest_journeys.sql rename to models/intermediate/kpis/int_kpis__agg_mtd_check_in_attrib_guest_journeys.sql index 8190595..dbdbc62 100644 --- a/models/intermediate/kpis/int_kpis__aggregated_monthly_check_in_attributed_guest_journeys.sql +++ b/models/intermediate/kpis/int_kpis__agg_mtd_check_in_attrib_guest_journeys.sql @@ -27,9 +27,9 @@ sum(created_guest_journeys) as created_guest_journeys, sum(started_guest_journeys) as started_guest_journeys, sum(completed_guest_journeys) as completed_guest_journeys - from {{ ref("int_kpis__metric_monthly_check_in_attributed_guest_journeys") }} + from {{ ref("int_kpis__metric_mtd_check_in_attrib_guest_journeys") }} group by 1, 2, 3, 4 {% if not loop.last %} union all {% endif %} -{% endfor %} +{% endfor %} \ No newline at end of file diff --git a/models/intermediate/kpis/int_kpis__metric_daily_check_in_attributed_guest_journeys.sql b/models/intermediate/kpis/int_kpis__metric_daily_check_in_attrib_guest_journeys.sql similarity index 100% rename from models/intermediate/kpis/int_kpis__metric_daily_check_in_attributed_guest_journeys.sql rename to models/intermediate/kpis/int_kpis__metric_daily_check_in_attrib_guest_journeys.sql diff --git a/models/intermediate/kpis/int_kpis__metric_monthly_check_in_attributed_guest_journeys.sql b/models/intermediate/kpis/int_kpis__metric_monthly_check_in_attrib_guest_journeys.sql similarity index 93% rename from models/intermediate/kpis/int_kpis__metric_monthly_check_in_attributed_guest_journeys.sql rename to models/intermediate/kpis/int_kpis__metric_monthly_check_in_attrib_guest_journeys.sql index c47a0e7..8e1f05d 100644 --- a/models/intermediate/kpis/int_kpis__metric_monthly_check_in_attributed_guest_journeys.sql +++ b/models/intermediate/kpis/int_kpis__metric_monthly_check_in_attrib_guest_journeys.sql @@ -26,7 +26,7 @@ select sum(b.completed_guest_journeys) as completed_guest_journeys from {{ ref("int_kpis__dimension_dates") }} d left join - {{ ref("int_kpis__metric_daily_check_in_attributed_guest_journeys") }} b + {{ ref("int_kpis__metric_daily_check_in_attrib_guest_journeys") }} b on date_trunc('month', b.date)::date = d.first_day_month where d.is_end_of_month = true and b.id_deal is not null group by 1, 2, 3, 4, 5, 6, 7 diff --git a/models/intermediate/kpis/int_kpis__metric_mtd_check_in_attributed_guest_journeys.sql b/models/intermediate/kpis/int_kpis__metric_mtd_check_in_attrib_guest_journeys.sql similarity index 93% rename from models/intermediate/kpis/int_kpis__metric_mtd_check_in_attributed_guest_journeys.sql rename to models/intermediate/kpis/int_kpis__metric_mtd_check_in_attrib_guest_journeys.sql index fce8ec6..09e872e 100644 --- a/models/intermediate/kpis/int_kpis__metric_mtd_check_in_attributed_guest_journeys.sql +++ b/models/intermediate/kpis/int_kpis__metric_mtd_check_in_attrib_guest_journeys.sql @@ -26,7 +26,7 @@ select sum(b.completed_guest_journeys) as completed_guest_journeys from {{ ref("int_kpis__dimension_dates") }} d left join - {{ ref("int_kpis__metric_daily_check_in_attributed_guest_journeys") }} b + {{ ref("int_kpis__metric_daily_check_in_attrib_guest_journeys") }} b on date_trunc('month', b.date)::date = d.first_day_month and extract(day from b.date) <= d.day where d.is_month_to_date = true and b.id_deal is not null diff --git a/models/intermediate/kpis/schema.yml b/models/intermediate/kpis/schema.yml index 6deaffe..6883140 100644 --- a/models/intermediate/kpis/schema.yml +++ b/models/intermediate/kpis/schema.yml @@ -3076,7 +3076,7 @@ models: data_type: bigint description: The month-to-date cancelled bookings for a given date, dimension and value. - - name: int_kpis__metric_daily_check_in_attributed_guest_journeys + - name: int_kpis__metric_daily_check_in_attrib_guest_journeys description: | This model computes Guest Journey metrics at the deepest granularity level for the Guest Products KPIs. @@ -3178,7 +3178,7 @@ models: Count of daily guest journeys completed in a given date and per specified dimension. - - name: int_kpis__metric_monthly_check_in_attributed_guest_journeys + - name: int_kpis__metric_monthly_check_in_attrib_guest_journeys description: | This model computes the Monthly metrics associated with Guest Journeys attributed to Check-In date at the deepest granularity. @@ -3228,7 +3228,8 @@ models: - name: has_id_check data_type: boolean - description: True if the verification in the guest journey includes Government ID Check for the bookings. + description: True if the verification in the guest journey includes + Government ID Check for the bookings. tests: - not_null @@ -3297,13 +3298,11 @@ models: tests: - not_null - - name: int_kpis__aggregated_monthly_check_in_attributed_guest_journeys + - name: int_kpis__agg_monthly_check_in_attrib_guest_journeys description: | This model computes the dimension aggregation for Monthly metrics associated to Guest Journeys attributed to Check-In date. - The primary key of this model is end_date, dimension, and dimension_value. - tests: - dbt_utils.unique_combination_of_columns: combination_of_columns: @@ -3392,7 +3391,7 @@ models: tests: - not_null - - name: int_kpis__metric_mtd_check_in_attributed_guest_journeys + - name: int_kpis__metric_mtd_check_in_attrib_guest_journeys description: | This model computes the Month-To-Date metrics associated with Guest Journeys attributed to Check-In date at the deepest granularity. @@ -3512,13 +3511,11 @@ models: tests: - not_null - - name: int_kpis__aggregated_mtd_check_in_attributed_guest_journeys + - name: int_kpis__agg_mtd_check_in_attrib_guest_journeys description: | This model computes the dimension aggregation for Month-To-Date metrics associated to Guest Journeys attributed to Check-In date. - The primary key of this model is end_date, dimension, and dimension_value. - tests: - dbt_utils.unique_combination_of_columns: combination_of_columns: