fivetran / dbt_netsuite_source

Data models for Fivetran's Netsuite source package, built using dbt.
https://fivetran.github.io/dbt_netsuite_source/
Apache License 2.0
14 stars 20 forks source link

Feature/phillem15 customers stg #16

Closed phillem15 closed 2 years ago

phillem15 commented 2 years ago

Pull Request Are you a current Fivetran customer?

Yes! My name is Evan Phillips, Lead BI Architect for Nordic Global.

What change(s) does this PR introduce?

I have removed the _fivetran_synced column definition from the get_customers_columns macro because this was introducing an ambiguous column definition error when trying to pass the column to the customers_pass_through_columns variable. Since the column is defined in the macro, but not listed in the final CTE of the stg_netsuite__customers model, the field is technically duplicated in the fields CTE which caused the issue.

I chose to remove the column definition from the macro as this aligns to the pattern set forth by the other macros in this project.

Did you update the CHANGELOG?

Does this PR introduce a breaking change?

Since the column is not listed in the stg_netsuite__customers model an end user would have needed to pass the _fivetran_synced column to the pass through columns variable anyway, so removing the column definition from the macro would not introduce a change required by the end user.

Did you update the dbt_project.yml files with the version upgrade (please leverage standard semantic versioning)? (In both your main project and integration_tests)

Is this PR in response to a previously created Bug or Feature Request

How did you test the PR changes?

I tested this fix in my local dbt project for Nordic. All code ran as expected.

Select which warehouse(s) were used to test the PR

Provide an emoji that best describes your current mood

:robot: **Feedback** We are so excited you decided to contribute to the Fivetran community dbt package! We continue to work to improve the packages and would greatly appreciate your [feedback](https://www.surveymonkey.com/r/DQ7K7WW) on our existing dbt packages or what you'd like to see next.