Merged PR 2172: Adding accommodation metrics by deal id
Adding accommodation metrics by deal id with the model `int_core__monthly_accommodation_history_by_deal`. With this PR, we have the full set of batch 1 metrics by deal id completed, although separated in different tables. Aggregation will come in a separated PR. Similarly as the previous PR, this one it's a mix between the logic of `int_core__mtd_accommodation_metrics` and the logic existing for the `int_core__monthly_X_history_by_deal` . It also adds the tests in schema. Related work items: #17689
This commit is contained in:
parent
1a4b6b4c14
commit
f9741d6f69
2 changed files with 77 additions and 0 deletions
|
|
@ -143,6 +143,31 @@ models:
|
|||
- not_null
|
||||
- unique
|
||||
|
||||
- name: int_core__monthly_accommodation_history_by_deal
|
||||
description: |
|
||||
This model contains the historic information regarding the accommodations, also known
|
||||
as listings, for each deal id. It's used for the business KPIs in the view by deal id.
|
||||
Data is aggregated at the last day of the month, or up to yesterday if it's the
|
||||
current month.
|
||||
tests:
|
||||
- dbt_utils.unique_combination_of_columns:
|
||||
combination_of_columns:
|
||||
- date
|
||||
- id_deal
|
||||
|
||||
columns:
|
||||
- name: date
|
||||
data_type: date
|
||||
description: The last day of the month or yesterday for historic listing metrics.
|
||||
tests:
|
||||
- not_null
|
||||
|
||||
- name: id_deal
|
||||
data_type: character varying
|
||||
description: Id of the deal associated to the host.
|
||||
tests:
|
||||
- not_null
|
||||
|
||||
- name: int_core__monthly_booking_history_by_deal
|
||||
description: |
|
||||
This model contains the historic information regarding the bookings for each deal id.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue