mirror of
https://gitlab.com/cief-data/dbt_cloud.git
synced 2026-08-19 04:14:00 +00:00
added is_credit_term_company variable
This commit is contained in:
@@ -3,19 +3,23 @@ WITH company_connections AS (
|
|||||||
SELECT * FROM {{ source('src_shipping_mysql', 'company_connections') }}
|
SELECT * FROM {{ source('src_shipping_mysql', 'company_connections') }}
|
||||||
),
|
),
|
||||||
|
|
||||||
|
|
||||||
-- LOGIC
|
-- LOGIC
|
||||||
company_connections_rename AS (
|
company_connections_rename AS (
|
||||||
|
|
||||||
SELECT
|
SELECT
|
||||||
company_connections.id AS sub_company_marking_connection_id,
|
company_connections.id AS sub_company_marking_connection_id,
|
||||||
company_connections.invitee_id AS sub_company_id,
|
company_connections.invitee_id AS sub_company_id,
|
||||||
company_connections.invitee_reference AS sub_company_marking_id,
|
company_connections.invitee_reference AS sub_company_marking_id,
|
||||||
company_connections.status,
|
company_connections.status,
|
||||||
company_connections.created_at AS created_datetime,
|
company_connections.is_credit_term AS is_credit_term_company,
|
||||||
company_connections.updated_at AS updated_datetime,
|
company_connections.created_at AS created_datetime,
|
||||||
|
company_connections.updated_at AS updated_datetime,
|
||||||
|
|
||||||
'{{ modules.datetime.datetime.now(modules.pytz.timezone("Asia/Kuala_Lumpur")) }}' AS _dbt_ran_datetime
|
'{{ modules.datetime.datetime.now(modules.pytz.timezone("Asia/Kuala_Lumpur")) }}' AS _dbt_ran_datetime
|
||||||
|
|
||||||
FROM company_connections
|
FROM company_connections
|
||||||
|
|
||||||
),
|
),
|
||||||
|
|
||||||
|
|
||||||
@@ -30,6 +34,7 @@ final__base_shipping__sub_company_marking_connections AS (
|
|||||||
|
|
||||||
-- dimensions
|
-- dimensions
|
||||||
status,
|
status,
|
||||||
|
is_credit_term_company,
|
||||||
|
|
||||||
-- measures
|
-- measures
|
||||||
|
|
||||||
@@ -41,6 +46,7 @@ final__base_shipping__sub_company_marking_connections AS (
|
|||||||
_dbt_ran_datetime
|
_dbt_ran_datetime
|
||||||
|
|
||||||
FROM company_connections_rename
|
FROM company_connections_rename
|
||||||
|
|
||||||
)
|
)
|
||||||
|
|
||||||
SELECT * FROM final__base_shipping__sub_company_marking_connections
|
SELECT * FROM final__base_shipping__sub_company_marking_connections
|
||||||
Reference in New Issue
Block a user