@@ -30,14 +30,14 @@ models:
30
30
group : analytics
31
31
latest_version : 2
32
32
config :
33
- contract :
33
+ contract :
34
34
enforced : true
35
35
event_time : " created_at"
36
36
columns :
37
37
- name : id
38
38
description : " The primary key for this table"
39
39
data_type : int
40
- constraints :
40
+ constraints :
41
41
- type : not_null
42
42
- type : unique
43
43
- type : check
@@ -69,7 +69,7 @@ models:
69
69
- type : unique
70
70
columns : [ color, date_day ]
71
71
name : strange_uniqueness_requirement
72
-
72
+
73
73
- name : my_materialized_view
74
74
config :
75
75
materialized : materialized_view
@@ -89,7 +89,7 @@ unit_tests:
89
89
- {id: 1, code: 'abc'}
90
90
- {id: 2, code: 'def'}
91
91
model : my_first_dbt_model
92
-
92
+
93
93
- name : my_second_unit_test
94
94
expect :
95
95
rows :
@@ -100,13 +100,13 @@ unit_tests:
100
100
tags : ['tag_1', 'tag_2']
101
101
description : This checks the validity of the model
102
102
overrides :
103
- macros :
103
+ macros :
104
104
is_incremental : true
105
105
env_vars :
106
106
my_first_var : 12345
107
107
vars :
108
108
my_second_var : 689
109
-
109
+
110
110
- name : my_inline_csv_unit_test
111
111
given :
112
112
- input : ref('model_b')
@@ -147,7 +147,7 @@ snapshots:
147
147
group : analytics
148
148
description : slowly changing dimension
149
149
columns :
150
- - name : id
150
+ - name : id
151
151
description : cool column, eh?
152
152
153
153
- name : yaml_defined_snapshot
@@ -159,7 +159,7 @@ snapshots:
159
159
strategy : timestamp
160
160
updated_at : updated_at
161
161
162
- # model groups
162
+ # model groups
163
163
164
164
groups :
165
165
- name : analytics
@@ -177,9 +177,15 @@ semantic_models:
177
177
- name : customer
178
178
expr : customer_id
179
179
type : primary
180
+ config :
181
+ meta :
182
+ contains_pii : false
180
183
dimensions :
181
184
- name : customer_name
182
185
type : categorical
186
+ config :
187
+ meta :
188
+ contains_pii : true
183
189
- name : customer_type
184
190
type : categorical
185
191
- name : first_ordered_at
@@ -194,6 +200,9 @@ semantic_models:
194
200
- name : count_lifetime_orders
195
201
description : Total count of orders per customer.
196
202
agg : sum
203
+ config :
204
+ meta :
205
+ contains_pii : false
197
206
- name : lifetime_spend_pretax
198
207
description : Customer lifetime spend before taxes.
199
208
agg : sum
@@ -218,7 +227,7 @@ metrics:
218
227
label : New Customers
219
228
type : simple
220
229
type_params :
221
- measure :
230
+ measure :
222
231
name : customers_with_orders
223
232
filter : |
224
233
{{ Dimension('customer__customer_type') }} = 'new'
@@ -263,11 +272,11 @@ metrics:
263
272
{{ Dimension('order__is_food_order') }} = True
264
273
265
274
- name : cumulative_order_total_l1m
266
- label : Cumulative Order total (L1M)
275
+ label : Cumulative Order total (L1M)
267
276
description : Trailing 1-month cumulative order amount
268
277
type : cumulative
269
278
type_params :
270
- measure :
279
+ measure :
271
280
name : order_total
272
281
fill_nulls_with : 0
273
282
window : 1 month
@@ -281,11 +290,11 @@ metrics:
281
290
calculation : conversions
282
291
base_measure :
283
292
name : visits
284
- conversion_measure :
293
+ conversion_measure :
285
294
name : buys
286
295
fill_nulls_with : 0
287
296
entity : user
288
- window : 7 days
297
+ window : 7 days
289
298
290
299
saved_queries :
291
300
- name : test_saved_query
@@ -310,7 +319,7 @@ saved_queries:
310
319
sources :
311
320
- name : some_source_name
312
321
loaded_at_field : _etl_loaded_at
313
- freshness :
322
+ freshness :
314
323
error_after :
315
324
count : 2
316
325
period : day
@@ -330,4 +339,4 @@ sources:
330
339
331
340
data_tests :
332
341
- name : my_cool_custom_test
333
- description : " This checks that all numbers are positive, if it fails you should talk to data engineering"
342
+ description : " This checks that all numbers are positive, if it fails you should talk to data engineering"
0 commit comments