Updating with Ray's comments
This commit is contained in:
parent
7a77691b89
commit
46d5e7c3c5
2 changed files with 39 additions and 15 deletions
|
|
@ -14,7 +14,6 @@ select
|
||||||
when version = 'V1' then 'Guesty' when version = 'V2' then 'Edeposit' else null
|
when version = 'V1' then 'Guesty' when version = 'V2' then 'Edeposit' else null
|
||||||
end as verification_source,
|
end as verification_source,
|
||||||
verification_status,
|
verification_status,
|
||||||
verification_status_reason,
|
|
||||||
nightly_fee_local,
|
nightly_fee_local,
|
||||||
cast(checkout_at_utc as date) - cast(checkin_at_utc as date) as number_nights,
|
cast(checkout_at_utc as date) - cast(checkin_at_utc as date) as number_nights,
|
||||||
email_flag,
|
email_flag,
|
||||||
|
|
@ -27,6 +26,7 @@ select
|
||||||
cast(checkout_at_utc as date) as checkout_date_utc,
|
cast(checkout_at_utc as date) as checkout_date_utc,
|
||||||
is_cancelled,
|
is_cancelled,
|
||||||
cancelled_at_utc,
|
cancelled_at_utc,
|
||||||
|
cast(cancelled_at_utc as date) as cancelled_date_utc,
|
||||||
user_email,
|
user_email,
|
||||||
guest_email,
|
guest_email,
|
||||||
guest_last_name,
|
guest_last_name,
|
||||||
|
|
@ -43,7 +43,11 @@ select
|
||||||
level_of_protection_amount,
|
level_of_protection_amount,
|
||||||
level_of_protection_currency,
|
level_of_protection_currency,
|
||||||
status_updated_at_utc,
|
status_updated_at_utc,
|
||||||
|
cast(status_updated_date_utc as date) as status_updated_date_utc,
|
||||||
updated_at_utc,
|
updated_at_utc,
|
||||||
|
cast(updated_at_utc as date) as updated_date_utc,
|
||||||
creation_at_utc,
|
creation_at_utc,
|
||||||
created_at_utc
|
cast(creation_at_utc as date) as creation_date_utc,
|
||||||
|
created_at_utc,
|
||||||
|
cast(created_at_utc as date) as created_date_utc
|
||||||
from stg_edeposit__verifications
|
from stg_edeposit__verifications
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,11 @@ models:
|
||||||
"This table holds records on verifications for e-deposit bookings.
|
"This table holds records on verifications for e-deposit bookings.
|
||||||
It contains details on validations checked on the guests, guest information
|
It contains details on validations checked on the guests, guest information
|
||||||
and some booking details like checkin-checkout date or the status of the verification.
|
and some booking details like checkin-checkout date or the status of the verification.
|
||||||
The id values found here are completely unrelated to the ones found in Core DWH."
|
The id values found here are completely unrelated to the ones found in Core DWH.
|
||||||
|
|
||||||
|
Note that id_verifications and booking_id should normally be 1 to 1.
|
||||||
|
Though there are exception, the API will accept a duplicate booking and the users
|
||||||
|
will be charged for it. A duplicate would return a unique id_verification."
|
||||||
columns:
|
columns:
|
||||||
- name: id_verification
|
- name: id_verification
|
||||||
data_type: text
|
data_type: text
|
||||||
|
|
@ -53,10 +57,6 @@ models:
|
||||||
data_type: text
|
data_type: text
|
||||||
description: "status of the verification"
|
description: "status of the verification"
|
||||||
|
|
||||||
- name: verification_status_reason
|
|
||||||
data_type: text
|
|
||||||
description: "short explanation for status"
|
|
||||||
|
|
||||||
- name: nightly_fee_local
|
- name: nightly_fee_local
|
||||||
data_type: double precision
|
data_type: double precision
|
||||||
description: "fee charged per night"
|
description: "fee charged per night"
|
||||||
|
|
@ -67,15 +67,15 @@ models:
|
||||||
|
|
||||||
- name: email_flag
|
- name: email_flag
|
||||||
data_type: text
|
data_type: text
|
||||||
description: ""
|
description: "screening result for email"
|
||||||
|
|
||||||
- name: phone_flag
|
- name: phone_flag
|
||||||
data_type: text
|
data_type: text
|
||||||
description: ""
|
description: "screening result for phone"
|
||||||
|
|
||||||
- name: watch_list
|
- name: watch_list
|
||||||
data_type: text
|
data_type: text
|
||||||
description: ""
|
description: "screening result of the guest"
|
||||||
|
|
||||||
- name: channel
|
- name: channel
|
||||||
data_type: text
|
data_type: text
|
||||||
|
|
@ -87,7 +87,7 @@ models:
|
||||||
|
|
||||||
- name: checkin_date_utc
|
- name: checkin_date_utc
|
||||||
data_type: date
|
data_type: date
|
||||||
description: "Timestamp of checkin for the booking"
|
description: "Date of checkin for the booking"
|
||||||
|
|
||||||
- name: checkout_at_utc
|
- name: checkout_at_utc
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
|
|
@ -95,7 +95,7 @@ models:
|
||||||
|
|
||||||
- name: checkout_date_utc
|
- name: checkout_date_utc
|
||||||
data_type: date
|
data_type: date
|
||||||
description: "Timestamp of checkout for the booking"
|
description: "Date of checkout for the booking"
|
||||||
|
|
||||||
- name: is_cancelled
|
- name: is_cancelled
|
||||||
data_type: boolean
|
data_type: boolean
|
||||||
|
|
@ -105,6 +105,10 @@ models:
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: "Timestamp of cancellation of the booking"
|
description: "Timestamp of cancellation of the booking"
|
||||||
|
|
||||||
|
- name: cancelled_date_utc
|
||||||
|
data_type: date
|
||||||
|
description: "Date of cancellation for the booking"
|
||||||
|
|
||||||
- name: user_email
|
- name: user_email
|
||||||
data_type: text
|
data_type: text
|
||||||
description: ""
|
description: ""
|
||||||
|
|
@ -169,14 +173,30 @@ models:
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: "Timestamp when status was last updated"
|
description: "Timestamp when status was last updated"
|
||||||
|
|
||||||
|
- name: status_updated_date_utc
|
||||||
|
data_type: date
|
||||||
|
description: "Date of last status update of the verification"
|
||||||
|
|
||||||
- name: updated_at_utc
|
- name: updated_at_utc
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: "Timestamp of last updated"
|
description: "Timestamp of last updated of the verification"
|
||||||
|
|
||||||
|
- name: updated_date_utc
|
||||||
|
data_type: date
|
||||||
|
description: "Date of last update of the verification"
|
||||||
|
|
||||||
- name: creation_at_utc
|
- name: creation_at_utc
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: ""
|
description: "Athena timestamp field of when the booking was created"
|
||||||
|
|
||||||
|
- name: creation_date_utc
|
||||||
|
data_type: date
|
||||||
|
description: "Athena date field of when the booking was created"
|
||||||
|
|
||||||
- name: created_at_utc
|
- name: created_at_utc
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: ""
|
description: "Timestamp of creation of the verification in the system"
|
||||||
|
|
||||||
|
- name: created_date_utc
|
||||||
|
data_type: date
|
||||||
|
description: "Date of creation of the verification in the system"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue