diff --git a/definitions/gold/ALL_INTERACRIONS_SUM.sqlx b/definitions/gold/ALL_INTERACRIONS_SUM.sqlx index 4cdc93d..a1ecc2c 100644 --- a/definitions/gold/ALL_INTERACRIONS_SUM.sqlx +++ b/definitions/gold/ALL_INTERACRIONS_SUM.sqlx @@ -10,7 +10,7 @@ config { } select TIMESTAMP, - DATE, + replace(safe_cast(safe_cast(cl.DATE as date) as string), '-', '') DATE, HOUR_OF_DAY, MONTH, YEAR, @@ -20,7 +20,7 @@ select TIMESTAMP, from ${ref("CALLS")} union all select TIMESTAMP, - DATE, + replace(safe_cast(safe_cast(cl.DATE as date) as string), '-', '') DATE, HOUR_OF_DAY, MONTH, YEAR, diff --git a/definitions/staging/stg_CALLS.sqlx b/definitions/staging/stg_CALLS.sqlx index db2feed..84b822c 100644 --- a/definitions/staging/stg_CALLS.sqlx +++ b/definitions/staging/stg_CALLS.sqlx @@ -10,7 +10,7 @@ config { } select cl.TIMESTAMP, - cl.DATE, + replace(safe_cast(safe_cast(cl.DATE as date) as string), '-', '') DATE, cl.HOUR_OF_DAY, cl.DAY_OF_WEEK, cl.MONTH, diff --git a/definitions/staging/stg_DIGITAL.sqlx b/definitions/staging/stg_DIGITAL.sqlx index eaa29d9..aae786a 100644 --- a/definitions/staging/stg_DIGITAL.sqlx +++ b/definitions/staging/stg_DIGITAL.sqlx @@ -10,7 +10,7 @@ config { } select dl.TIMESTAMP, - dl.DATE, + replace(safe_cast(safe_cast(dl.DATE as date) as string), '-', '') DATE, dl.HOUR_OF_DAY, dl.MONTH, dl.YEAR,