File tree 1 file changed +34
-0
lines changed
website/docs/reference/dbt-jinja-functions
1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ title : " About properties.yml context"
3
+ sidebar_label : " properties.yml context"
4
+ id : " dbt-properties-yml-context"
5
+ description : " The context methods and variables available when configuring resources in a properties.yml file."
6
+ ---
7
+
8
+ The following context methods and variables are available when configuring
9
+ resources in a ` properties.yml ` file.
10
+
11
+ ** Available context methods:**
12
+ - [ env_var] ( /reference/dbt-jinja-functions/env_var )
13
+ - [ var] ( /reference/dbt-jinja-functions/var )
14
+
15
+ ** Available context variables:**
16
+ - [ target] ( /reference/dbt-jinja-functions/target )
17
+ - [ builtins] ( /reference/dbt-jinja-functions/builtins )
18
+ - [ dbt_version] ( /reference/dbt-jinja-functions/dbt_version )
19
+
20
+ ### Example configuration
21
+
22
+ <File name =' properties.yml ' >
23
+
24
+ ``` yml
25
+ # Configure this model to be materialized as a view
26
+ # in development and a table in production/CI contexts
27
+
28
+ models :
29
+ - name : dim_customers
30
+ config :
31
+ materialized : " {{ 'view' if target.name == 'dev' else 'table' }}"
32
+ ` ` `
33
+
34
+ </File>
You can’t perform that action at this time.
0 commit comments