-
Notifications
You must be signed in to change notification settings - Fork 104
Open
Labels
Milestone
Description
we should try and standardize on a convention of using {{ relation }} wherever possible over these variants:
{{ relation.schema }}.{{ relation.identifier }}to_relation.schema ~ '.' ~ to_relation.identifier
@jtcohen6, how do we disable by default database being included when calling {{ relation }}? Do we have create a child of the Relation class?
| EXEC('CREATE SCHEMA {{ relation.without_identifier().schema }}') |
| create view {{ relation.schema }}.{{ relation.identifier }} as |
| EXEC sp_rename '{{ from_relation.schema }}.{{ from_relation.identifier }}', '{{ to_relation.identifier }}' |
| {%- set full_relation = relation.schema ~ '.' ~ relation.identifier -%} |
dbt-sqlserver/dbt/include/sqlserver/macros/adapters.sql
Lines 152 to 154 in 4b3f7bc
| EXEC('create view {{ tmp_relation.schema }}.{{ tmp_relation.identifier }} as | |
| {{ temp_view_sql }} | |
| '); |
dbt-sqlserver/dbt/include/sqlserver/macros/adapters.sql
Lines 168 to 169 in 4b3f7bc
| {%- set full_to_relation = to_relation.schema ~ '.' ~ to_relation.identifier -%} | |
| {%- set full_from_relation = from_relation.schema ~ '.' ~ from_relation.identifier -%} |