Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix syntax errors #705

Merged
merged 2 commits into from
Oct 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ numerator_1,numerator_2,denominator,output
0,0,0,
3,4,,
,6,14,
2,5,2,5

2,5,2,5
8 changes: 5 additions & 3 deletions integration_tests/models/sql/test_safe_divide.sql
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@

with data_safe_divide as (

select * from {{ ref('data_safe_divide') }}

),

data_safe_divide_numerator_expressions (
data_safe_divide_numerator_expressions as (

select * from {{ ref('data_safe_divide_numerator_expressions') }}
),

data_safe_divide_denominator_expressions (
data_safe_divide_denominator_expressions as (

select * from {{ ref('data_safe_divide_denominator_expressions') }}
)
Expand All @@ -26,11 +26,13 @@ union all
select
{{ dbt_utils.safe_divide('numerator_1 * numerator_2', 'denominator') }} as actual,
output as expected

from data_safe_divide_numerator_expressions

union all

select
{{ dbt_utils.safe_divide('numerator', 'denominator_1 * denominator_2') }} as actual,
output as expected

from data_safe_divide_denominator_expressions