work
This commit is contained in:
parent
5b5c878c2a
commit
3620401037
2 changed files with 27 additions and 12 deletions
|
|
@ -14,23 +14,38 @@ sources:
|
||||||
tests:
|
tests:
|
||||||
- unique
|
- unique
|
||||||
- not_null
|
- not_null
|
||||||
# - dbt_expectations.expect_column_values_to_match_regex:
|
- dbt_expectations.expect_column_values_to_match_regex:
|
||||||
# regex: "^[0-9A-Fa-f]{8}-[0-9A-Fa-f]{4}-4[0-9A-Fa-f]{3}-[89ABab][0-9A-Fa-f]{3}-[0-9A-Fa-f]{12}$"
|
regex: "^[0-9A-Fa-f]{8}-[0-9A-Fa-f]{4}-4[0-9A-Fa-f]{3}-[89ABab][0-9A-Fa-f]{3}-[0-9A-Fa-f]{12}$"
|
||||||
- name: code
|
- name: Code
|
||||||
data_type: bigint
|
data_type: bigint
|
||||||
description: ""
|
quote: True
|
||||||
- name: email
|
description: "WIP. Is this an increment unique ID?"
|
||||||
|
tests:
|
||||||
|
- unique
|
||||||
|
- not_null
|
||||||
|
- name: Email
|
||||||
data_type: character varying
|
data_type: character varying
|
||||||
description: ""
|
quote: True
|
||||||
- name: title
|
description: "Email for this user."
|
||||||
|
tests:
|
||||||
|
- unique
|
||||||
|
- not_null
|
||||||
|
- name: Title
|
||||||
data_type: character varying
|
data_type: character varying
|
||||||
|
quote: True
|
||||||
description: ""
|
description: ""
|
||||||
- name: dealid
|
- name: DealId
|
||||||
data_type: character varying
|
data_type: character varying
|
||||||
description: ""
|
quote: True
|
||||||
- name: deleted
|
description: "The Hubspot Deal Id that this user account belongs to. Multiple users can all be part of one Deal."
|
||||||
|
# This test can't be enforced yet due to some bad test data in the production database. Once that's deal with, this should be activated.
|
||||||
|
#tests:
|
||||||
|
# - dbt_expectations.expect_column_values_to_match_regex:
|
||||||
|
# regex: "^[0-9]{10,11}$"
|
||||||
|
- name: Deleted
|
||||||
data_type: boolean
|
data_type: boolean
|
||||||
description: ""
|
quote: True
|
||||||
|
description: "WIP. I'm guessing this signals that the user wanted to be deleted?"
|
||||||
- name: joindate
|
- name: joindate
|
||||||
data_type: timestamp without time zone
|
data_type: timestamp without time zone
|
||||||
description: ""
|
description: ""
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
with
|
with
|
||||||
raw_user as (select * from {{ source("core", "user") }}),
|
raw_user as (select * from {{ source("core", "User") }}),
|
||||||
stg_core__user as (
|
stg_core__user as (
|
||||||
select
|
select
|
||||||
{{ adapter.quote("Id") }} as id_user,
|
{{ adapter.quote("Id") }} as id_user,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue