This commit is contained in:
Pablo Martin 2025-07-11 16:15:17 +02:00
parent 729d6d6db4
commit a256b48b01
630 changed files with 16494 additions and 0 deletions

View file

@ -0,0 +1,40 @@
# Credit Notes Downstream Analysis
# Base Model
`int_xero__credit_notes`
![image.png](image%202.png)
# Downstream Models
- `int_xero__credit_note_line_items`
- No aggregations
- `int_xero__sales_denom_mart`
- No aggregations
- `int_xero__sales_monthly_trends`
- Aggregated at accounting financial level, need to update seed model with Resolution account codes
- `xero__credit_note_line_items`
- No aggregations
- `xero__credit_notes`
- No aggregations
- `xero__net_fees`
- Double check on this, but it shouldnt affect since its grouped by `item_code` which is null for Host Resolution payments.
Indeed this change doesnt affect for the reason previously mentioned
- `xero__net_fees_by_deal`
- This model would be affected by it since its aggregating all invoices and credit notes regardless of the type they are by `date` and `id_deal` .
- Possible solution would be to add a new field `is_resolution_payout` in `xero__credit_notes` and use this field to filter out all credit notes from Resolutions Payouts
- `xero__sales_denom_mart`
- No aggregations
- `xero__sales_monthly_trends`
- No aggregations
- We do need to include the new `account_code` for all Resolutions Payouts to `stg_seed__accounting_aggregations`
- `int_kpis__metric_daily_invoiced_revenue`
- It does add new records but with all dimension values as 0 since the model adds the values filtering be `accounting_root_aggregation` or `accounting_kpis_aggregation` set for the different account codes in `stg_seed__accounting_aggregations`
This already adds records with all dimension values as 0 for every other account code that is not in `stg_seed__accounting_aggregations`
- `int_kpis__metric_daily_total_and_retained_revenue`
- No impact since it aggregates by the different revenue sources
- `int_kpis__metric_monthly_invoiced_revenue`
- No impact since it aggregates by the different revenue sources
- `int_kpis__metric_mtd_invoiced_revenue`
- No impact since it aggregates by the different revenue sources