data-dwh-dbt-project/models/intermediate/cross
Oriol Roqué Paniagua 29a005297a Merged PR 3906: Adds 2 new retained income metrics
# Description

It adds 2 new metrics in Main KPIs, both for Global/per Dimension and By Deal. If merged, metrics will NOT appear automatically in the Global/per Dimension nor in the By Deal.

These two new metrics are:
* Income Retained: Total Revenue - Waiver Paid Back to Host
* Income Retained Post Resolutions: Total Revenue - Waiver Paid Back to Host - Host Resolutions Amount Paid

Why these are important:

![image.png](https://guardhog.visualstudio.com/4148d95f-4b6d-4205-bcff-e9c8e0d2ca65/_apis/git/repositories/54ac356f-aad7-46d2-b62c-e8c5b3bb8ebf/pullRequests/3906/attachments/image.png)

Even though we grow considerably in terms of Revenue, the gap of Waivers that we pay back to host is also increasing. Thus the "real" increment is actually lower. However, what I find more interesting is the heavy decrease in Income Retained Post Resolutions. Here's the Year-by-Year comparison:

![image (2).png](https://guardhog.visualstudio.com/4148d95f-4b6d-4205-bcff-e9c8e0d2ca65/_apis/git/repositories/54ac356f-aad7-46d2-b62c-e8c5b3bb8ebf/pullRequests/3906/attachments/image%20%282%29.png)

In November 2024, we're back to the figures of 2023 (-0.4%) and this should be alarming considering we're growing in Total Revenue by 27% and in Retained Income by 41% vs. Nov 23. In terms of business impact, I'd opt for having these 2 metrics computed as these capture a reality that otherwise we keep hidden. Happy to discuss renames and how/if we move forward with this.

# Checklist

- [X] The edited models and dependants run properly with production data.
- [X] The edited models are sufficiently documented.
- [X] The edited models contain PK tests, and I've ran and passed them.
- [X] I have checked for DRY opportunities with other models and docs.
- [X] I've picked the right materialization for the affected models.

# Other

- [ ] Check if a full-refresh is required after this PR is merged.

Attached working excel with the extraction
[20241227_retained_revenue_global.xlsx](https://guardhog.visualstudio.com/4148d95f-4b6d-4205-bcff-e9c8e0d2ca65/_apis/git/repositories/54ac356f-aad7-46d2-b62c-e8c5b3bb8ebf/pullRequests/3906/attachments/20241227_retained_revenue_global.xlsx)

Related work items: #25804
2024-12-31 12:10:12 +00:00
..
int_daily_currency_exchange_rates.sql go back to var, made a mistake in the last commit 2024-06-17 11:32:20 +02:00
int_dates.sql start cross folder in int to stop piling models at int root 2024-06-14 16:26:18 +02:00
int_edeposit_and_athena_verifications.sql fixed number of nights in edeposit 2024-12-16 13:53:57 +01:00
int_monthly_12m_window_contribution_by_deal.sql fixed int_monthly_12m_window_contribution_by_deal 2024-11-05 12:53:27 +01:00
int_monthly_aggregated_metrics_history_by_deal.sql Merged PR 3906: Adds 2 new retained income metrics 2024-12-31 12:10:12 +00:00
int_monthly_churn_metrics.sql Merged PR 3482: Adapts date dimension skeleton for Main KPIs 2024-11-11 15:57:37 +00:00
int_monthly_growth_score_by_deal.sql fixed int_monthly_growth_score_by_deal 2024-11-05 12:49:50 +01:00
int_mtd_aggregated_metrics.sql Merged PR 3906: Adds 2 new retained income metrics 2024-12-31 12:10:12 +00:00
int_mtd_vs_previous_year_metrics.sql Merged PR 3906: Adds 2 new retained income metrics 2024-12-31 12:10:12 +00:00
int_simple_exchange_rates.sql simple model 2024-06-14 16:44:40 +02:00
schema.yml Merged PR 3810: Adds is_end_of_month_or_yesterday for Main KPIs 2024-12-09 16:13:52 +00:00