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

Revert "Feature/safe divide" #702

Merged
merged 1 commit into from
Oct 11, 2022
Merged

Conversation

deanna-minnick
Copy link
Contributor

Reverts #697

@joellabes joellabes merged commit 6a5dd1e into main Oct 11, 2022
joellabes added a commit that referenced this pull request Nov 22, 2022
* Feature/safe divide (#697)

* add safe_divide documentation

* add safe_divide macro

* add integration test for safe_divide macro

* moved macro and documentation to new SQL generator section

Co-authored-by: Grace Goheen <graciegoheen@gmail.com>

* Revert "Feature/safe divide (#697)" (#702)

This reverts commit f368cec.

* Quick nitpicks (#718)

I was doing some studying on these and spotted some stuff. One verb conjugation and a consistency in macro description

Co-authored-by: deanna-minnick <41010575+deanna-minnick@users.noreply.github.com>
Co-authored-by: Grace Goheen <graciegoheen@gmail.com>
Co-authored-by: ian-fahey-dbt <107962364+ian-fahey-dbt@users.noreply.github.com>
joellabes added a commit to yuanminglee/dbt-utils that referenced this pull request Nov 24, 2022
commit 04536a1
Author: Joel Labes <joel.labes@dbtlabs.com>
Date:   Wed Nov 23 08:30:34 2022 +1300

    Merge main into utils-v1 (dbt-labs#726)

    * Feature/safe divide (dbt-labs#697)

    * add safe_divide documentation

    * add safe_divide macro

    * add integration test for safe_divide macro

    * moved macro and documentation to new SQL generator section

    Co-authored-by: Grace Goheen <graciegoheen@gmail.com>

    * Revert "Feature/safe divide (dbt-labs#697)" (dbt-labs#702)

    This reverts commit f368cec.

    * Quick nitpicks (dbt-labs#718)

    I was doing some studying on these and spotted some stuff. One verb conjugation and a consistency in macro description

    Co-authored-by: deanna-minnick <41010575+deanna-minnick@users.noreply.github.com>
    Co-authored-by: Grace Goheen <graciegoheen@gmail.com>
    Co-authored-by: ian-fahey-dbt <107962364+ian-fahey-dbt@users.noreply.github.com>

commit 2703459
Author: fivetran-catfritz <111930712+fivetran-catfritz@users.noreply.github.com>
Date:   Tue Nov 1 20:26:17 2022 -0500

    Slugify for snowflake (dbt-labs#707)

commit 17b017d
Merge: 31c503d b08f7bb
Author: Joel Labes <joel.labes@dbtlabs.com>
Date:   Thu Oct 27 16:51:56 2022 +1300

    Merge branch 'heads/0.9.3' into utils-v1

commit b08f7bb
Author: Joel Labes <joel.labes@dbtlabs.com>
Date:   Thu Oct 27 15:28:55 2022 +1300

    Wrap xdb warnings in if execute block

commit 586f278
Author: Joel Labes <joel.labes@dbtlabs.com>
Date:   Thu Oct 27 15:27:57 2022 +1300

    Change deprecation resolution advice

commit 4fae6c5
Author: Joel Labes <joel.labes@dbtlabs.com>
Date:   Thu Oct 27 15:19:27 2022 +1300

    Switch to dbt.escape_single_quotes
joellabes added a commit that referenced this pull request Dec 1, 2022
* add safe_divide documentation

* add safe_divide macro

* add integration test for safe_divide macro

* Merge changes from main into utils v1 (#699)

* Correct link from README to the CONTRIBUTING guide. (#687)

* fix typo (#688)

Co-authored-by: Alex Malins <22991362+alexmalins@users.noreply.github.com>

* Change `escape_single_quotes` Reference in Pivot Macro (#692)

* Update pivot.sql

* Changelog Updates

Co-authored-by: Liam O'Boyle <github@elyobo.net>
Co-authored-by: Alex Malins <github@alexmalins.com>
Co-authored-by: Alex Malins <22991362+alexmalins@users.noreply.github.com>
Co-authored-by: zachoj10 <zjosephson@gmail.com>

* Use backwards comaptible versions of timestamp macro

* moved macro and documentation to new SQL generator section

* add tests with expressions

* fix syntax errors  (#705)

* fix syntax errors

* remove whitespace in seed file

* Restore dbt. prefix for all migrated cross-db macros (#701)

* added prefix dbt. on cross db macros

* Also prefix for new macro

* Adding changelog change

* Squashed commit of the following:

commit 5eba82b
Author: Deanna Minnick <deanna.e.minnick@gmail.com>
Date:   Wed Oct 12 10:30:42 2022 -0400

    remove whitespace in seed file

commit 7a2a5e3
Author: Deanna Minnick <deanna.e.minnick@gmail.com>
Date:   Wed Oct 12 10:22:07 2022 -0400

    fix syntax errors

Co-authored-by: Joel Labes <joel.labes@dbtlabs.com>

* Remove obsolete condition argument from expression_is_true (#700)

* Remove obsolete condition argument from expression_is_true

* Improve docs

* Improve docs

* Update star.sql to allow for non-quote wrapped column names (#706)

* Update star.sql

* Update star.sql

* feat: add testing to star macro 

column encased in quotes functionality

* chore: update schema.yml

* Update star.sql

* chore: update star.sql and schema.yml

* chore: update star.sql to trim blank space

* Update README.md

* Update README.md

adds example usage of star macro's quote_identifiers argument

Co-authored-by: crlough <connor.lough@pitchbook.com>

* Switch to dbt.escape_single_quotes

* Change deprecation resolution advice

* Wrap xdb warnings in if execute block

* Slugify for snowflake (#707)

* Merge main into utils-v1 (#726)

* Feature/safe divide (#697)

* add safe_divide documentation

* add safe_divide macro

* add integration test for safe_divide macro

* moved macro and documentation to new SQL generator section

Co-authored-by: Grace Goheen <graciegoheen@gmail.com>

* Revert "Feature/safe divide (#697)" (#702)

This reverts commit f368cec.

* Quick nitpicks (#718)

I was doing some studying on these and spotted some stuff. One verb conjugation and a consistency in macro description

Co-authored-by: deanna-minnick <41010575+deanna-minnick@users.noreply.github.com>
Co-authored-by: Grace Goheen <graciegoheen@gmail.com>
Co-authored-by: ian-fahey-dbt <107962364+ian-fahey-dbt@users.noreply.github.com>

* Feat: add macro get_query_results_as_single_value (#696)

* feat: add query_results_as_single_value.sql macro

* chore: update the macro definition

Current error to work through: "failed to find conversion function from unknown to text"

* chore: update test

* chore: final edits

* chore: remove extra model reference

* chore: update return() to handle BigQuery

* chore: README.md, macro updates

* feat: factoring in first review changes

* chore: updates to testing

* chore: updates tests

* chore: update test for bigquery

* chore: update cast for bigquery

* Use example with a single record in readme

* Add default value when no record found

* test when no results are found

* Rename test file

* Add test definitions

* Fix incorrect ref

* And another one

* Update test_get_query_results_as_single_value.sql

* cast strings as strings

* Put arg in right place

* Update test_get_query_results_as_single_value.sql

* switch to limit zero for BQ

* Update test_get_query_results_as_single_value.sql

* quote column name in arg

* snowflake wont let you safe cast something to itself

* warning to future readers [skip ci]

* Add singular test to check for multi row/multi column setup

* forgot to save comment [skip ci]

* Rename to get_single_value

Co-authored-by: crlough-gitkraken <loughondata@protonmail.com>
Co-authored-by: Joel Labes <joel.labes@dbtlabs.com>

* Remove rc1 requirement for utils v1

* Recency truncate date option (#731)

* WIP changing recency test

* Add tests

* cast to timestamp for bq

* forgot the curlies

* avoid lateral column aliasing

* ts not dt

* cast source as timestamp

* don't cast inside test

* cast as date instead of truncate

* Update recency.sql

* log bq events

* store pg artifacts

* int tests dir

* Correctly store artifacts

* try casting to date or datetime

* order of operations more like order of ooperations

* dt -> ts

* Do I really have to cast this?

* Revert "Do I really have to cast this?"

This reverts commit 21e2c0d.

* Output a warning when star finds no columns, not '*' (#732)

* Change star() behaviour when no columns returned

* Code review: return a * in compile mode

* README changes

* Delete xdb_deprecation_warning.sql

* Update README.md

* Remove from ToC

* Update toc

* Fix surrogate key variable example

Co-authored-by: Deanna Minnick <deanna.e.minnick@gmail.com>
Co-authored-by: Liam O'Boyle <github@elyobo.net>
Co-authored-by: Alex Malins <github@alexmalins.com>
Co-authored-by: Alex Malins <22991362+alexmalins@users.noreply.github.com>
Co-authored-by: zachoj10 <zjosephson@gmail.com>
Co-authored-by: Grace Goheen <graciegoheen@gmail.com>
Co-authored-by: deanna-minnick <41010575+deanna-minnick@users.noreply.github.com>
Co-authored-by: Simon Quvang <sikri19@student.sdu.dk>
Co-authored-by: miles <miles@bung.cc>
Co-authored-by: Connor <61797492+CR-Lough@users.noreply.github.com>
Co-authored-by: crlough <connor.lough@pitchbook.com>
Co-authored-by: fivetran-catfritz <111930712+fivetran-catfritz@users.noreply.github.com>
Co-authored-by: ian-fahey-dbt <107962364+ian-fahey-dbt@users.noreply.github.com>
Co-authored-by: crlough-gitkraken <loughondata@protonmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants