Skip to content

Commit

Permalink
Merge pull request #1019 from elexisvenator/comment-guard
Browse files Browse the repository at this point in the history
Add newline around SQL in incremental materialization to guard against line comments.
  • Loading branch information
drewbanin committed Sep 20, 2018
2 parents f588876 + 6652647 commit 5b94bc3
Showing 1 changed file with 3 additions and 1 deletion.
Expand Up @@ -60,7 +60,9 @@

{% set tmp_table_sql -%}
{# We are using a subselect instead of a CTE here to allow PostgreSQL to use indexes. -#}
select * from ({{ sql }}) as dbt_incr_sbq
select * from (
{{ sql }}
) as dbt_incr_sbq
where ({{ sql_where }})
or ({{ sql_where }}) is null
{%- endset %}
Expand Down

0 comments on commit 5b94bc3

Please sign in to comment.