accommodation staging model
This commit is contained in:
parent
f216e7708a
commit
26ce452a0c
1 changed files with 30 additions and 0 deletions
30
models/staging/core/stg_core__accommodation.sql
Normal file
30
models/staging/core/stg_core__accommodation.sql
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
with
|
||||
raw_accommodation as (select * from {{ source("core", "Accommodation") }}),
|
||||
stg_core__accommodation as (
|
||||
select
|
||||
{{ adapter.quote("AccommodationId") }} as id_accommodation,
|
||||
{{ adapter.quote("CreatedByUserId") }} as id_creating_user,
|
||||
{{ adapter.quote("PaymentValidationSetId") }} as id_payment_validation_set,
|
||||
{{ adapter.quote("FriendlyName") }} as friendly_name,
|
||||
{{ adapter.quote("CountryId") }} as id_country,
|
||||
{{ adapter.quote("IsActive") }} as is_active,
|
||||
{{ adapter.quote("Town") }} as town,
|
||||
{{ adapter.quote("Postcode") }} as postcode,
|
||||
{{ adapter.quote("AddressLine1") }} as address_line_1,
|
||||
{{ adapter.quote("AddressLine2") }} as address_line_2,
|
||||
{{ adapter.quote("VerificationLevel") }} as verification_level,
|
||||
{{ adapter.quote("ManuallyValidated") }} as manually_validated,
|
||||
{{ adapter.quote("FloorArea") }} as floor_area,
|
||||
{{ adapter.quote("NumberOfFloors") }} as number_of_floors,
|
||||
{{ adapter.quote("NumberOfBedrooms") }} as number_of_bedrooms,
|
||||
{{ adapter.quote("NumberOfBathrooms") }} as number_of_bathrooms,
|
||||
{{ adapter.quote("NumberOfOtherRooms") }} as number_of_other_rooms,
|
||||
{{ adapter.quote("DetailsOfConstruction") }} as construction_details,
|
||||
{{ adapter.quote("CreatedDate") }} as created_at_utc,
|
||||
{{ adapter.quote("UpdatedDate") }} as updated_at_utc,
|
||||
{{ adapter.quote("_airbyte_extracted_at") }} as dwh_extracted_at_utc
|
||||
|
||||
from raw_accommodation
|
||||
)
|
||||
select *
|
||||
from stg_core__accommodation
|
||||
Loading…
Add table
Add a link
Reference in a new issue