Skip to content

Commit

Permalink
changing files
Browse files Browse the repository at this point in the history
  • Loading branch information
TayDunlap committed Aug 13, 2024
1 parent 89bd730 commit fff40bc
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
5 changes: 5 additions & 0 deletions macros/create_schema.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{% macro create_schema(relation) %}
{%- call statement('create_schema') -%}
create schema if not exists {{ relation.without_identifier() }} with managed access
{% endcall %}
{% endmacro %}
8 changes: 7 additions & 1 deletion models/staging/tpch/stg_tpch_nations.sql
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{{
config(
schema='managed_access_test'
)
}}
with source as (

select * from {{ source('tpch', 'nation') }}
Expand All @@ -11,7 +16,8 @@ renamed as (
n_nationkey as nation_key,
n_name as name,
n_regionkey as region_key,
n_comment as comment
n_comment as comment,
'{{env_var('DBT_ENV_TYPE')}}' as env_type

from source

Expand Down

0 comments on commit fff40bc

Please sign in to comment.