schema and final touches for deal pipeline

This commit is contained in:
Pablo Martin 2024-10-14 11:47:44 +02:00
parent b9958129bc
commit 5c64bf8b20
2 changed files with 39 additions and 1 deletions

View file

@ -164,3 +164,42 @@ models:
description: "Timestamp of when data was extracted to DWH."
tests:
- not_null
- name: stg_hubspot__deal_pipelines
description: |
Details of the different deal pipelines. Deal pipelines are templates
for the stages a deal can go through. Typically, a deal can only be
in one pipeline. Pipelines have stages, which are stored in a different
table.
columns:
- name: id_deal_pipeline
data_type: character varying
description: "Unique id for each pipeline."
tests:
- not_null
- unique
- name: deal_pipeline_name
data_type: character varying
description: Name for the pipeline.
tests:
- not_null
- unique
- name: is_active
data_type: boolean
description: Flag indicating if the pipeline is currently active.
tests:
- not_null
- name: created_at_utc
data_type: timestamp
description: When was this record created.
tests:
- not_null
- name: updated_at_utc
data_type: timestamp
description: When was this record last updated.
tests:
- not_null

View file

@ -5,7 +5,6 @@ with
{{ adapter.quote("pipelineId") }} as id_deal_pipeline,
{{ adapter.quote("label") }} as deal_pipeline_name,
{{ adapter.quote("active") }} as is_active,
{{ adapter.quote("default") }} as is_default,
{{ adapter.quote("createdAt") }} as created_at_utc,
{{ adapter.quote("updatedAt") }} as updated_at_utc,
{{ adapter.quote("_airbyte_extracted_at") }} as dwh_extracted_at_utc