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

Added boolean data type #508

Closed
wants to merge 1 commit into from
Closed

Added boolean data type #508

wants to merge 1 commit into from

Conversation

Maayan-s
Copy link
Contributor

@Maayan-s Maayan-s commented Mar 1, 2022

This is a:

  • bug fix PR with no breaking changes — please ensure the base branch is main
  • new functionality — please ensure the base branch is the latest dev/ branch
  • a breaking change — please ensure the base branch is the latest dev/ branch

Description & motivation

Checklist

  • I have verified that these changes work locally on the following warehouses (Note: it's okay if you do not have access to all warehouses, this helps us understand what has been covered)
    • BigQuery
    • Postgres
    • Redshift
    • Snowflake
  • I followed guidelines to ensure that my changes will work on "non-core" adapters by:
    • dispatching any new macro(s) so non-core adapters can also use them (e.g. the star() source)
    • using the limit_zero() macro in place of the literal string: limit 0
    • using dbt_utils.type_* macros instead of explicit datatypes (e.g. dbt_utils.type_timestamp() instead of TIMESTAMP
  • I have updated the README.md (if applicable)
  • I have added tests & descriptions to my models (and macros if applicable)
  • I have added an entry to CHANGELOG.md

@joellabes
Copy link
Contributor

Hi @Maayan-s, thanks for opening this PR! Can you share more of your use case? It makes sense - we have a bunch of similar cross-db functionality, just wondering whether you need to use it in a package you're developing or something.

We're in the process of moving these into dbt Core (see #487 and for more), and the next minor version of dbt utils (coming in the next month or so) will reflect this change. Does that timeline work, or are you hoping that this would be available before then?

@Maayan-s
Copy link
Contributor Author

Maayan-s commented Mar 2, 2022

Hi @joellabes,
I am using these macros for type conversions in the package I'm developing, and the boolean conversion to support Snowflake, BigQuery and Redshift was missing.
I wrote it for myself, and figured I could contribute for others to enjoy as well.

@joellabes
Copy link
Contributor

OK thank you! I've included it in the list of macros to migrate: dbt-labs/dbt-core#4813. Since we're on the cusp of moving them all, it doesn't make sense to add it here just to remove it again, so I'm going to close this without merging. Thank you for bringing it up when you did!

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