new address_validation model in staging
This commit is contained in:
parent
cb3cf24b60
commit
cdd3b6a58f
3 changed files with 28 additions and 0 deletions
|
|
@ -225,3 +225,5 @@ sources:
|
|||
identifier: UserProductBundle
|
||||
- name: BookingToProductBundle
|
||||
identifier: BookingToProductBundle
|
||||
- name: AddressValidation
|
||||
identifier: AddressValidation
|
||||
|
|
|
|||
|
|
@ -169,6 +169,12 @@ models:
|
|||
- name: stg_core__booking_to_product_bundle
|
||||
columns:
|
||||
- name: id_booking_to_product_bundle
|
||||
tests:
|
||||
- unique
|
||||
- not_null
|
||||
- name: stg_core__address_validation
|
||||
columns:
|
||||
- name: id_address_validation
|
||||
tests:
|
||||
- unique
|
||||
- not_null
|
||||
20
models/staging/core/stg_core__address_validation.sql
Normal file
20
models/staging/core/stg_core__address_validation.sql
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
with
|
||||
raw_address_validation as (select * from {{ source("core", "AddressValidation") }}),
|
||||
stg_core__address_validation as (
|
||||
select
|
||||
{{ adapter.quote("Id") }} as id_address_validation,
|
||||
{{ adapter.quote("Notes") }} as notes,
|
||||
{{ adapter.quote("Passed") }} as validation_passed,
|
||||
{{ adapter.quote("CreatedDate") }} as created_at_utc,
|
||||
{{ adapter.quote("UpdatedDate") }} as updated_at_utc,
|
||||
{{ adapter.quote("AccommodationId") }} as id_accommodation,
|
||||
{{ adapter.quote("FeatureSizeMeters") }} as feature_size_meters,
|
||||
{{ adapter.quote("FeatureSizeMetersUpperLimit") }}
|
||||
as feature_size_meters_upper_limit,
|
||||
{{ adapter.quote("_airbyte_raw_id") }} as address_line_1,
|
||||
{{ adapter.quote("_airbyte_extracted_at") }} as dwh_extracted_at_utc
|
||||
|
||||
from raw_address_validation
|
||||
)
|
||||
select *
|
||||
from stg_core__address_validation
|
||||
Loading…
Add table
Add a link
Reference in a new issue