-
Notifications
You must be signed in to change notification settings - Fork 161
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
[ADAP-453] [Feature] Overwrite api.Column.string_type
#665
Comments
api.Column.string_type
api.Column.string_type
Yeah sure, sorry. As a heads up as well this issue is the same in databricks (spark I assume) as well - do you want me to raise a separate issue in that adaptors? The easiest way to see it is with a basic model that just casts something to the string type:
Which in the case of a BigQuery target leads to the following compiled code
and a
Because there is no overwritten function, it uses a the core class, which is I could swap out the |
Thanks @rlh1994 -- that is a perfect example 🏆 Based on the documentation for the select cast(10 as {{ api.Column.string_type(4000) }}) Suspected root causeThe primary testing for these two methods appears tautological to me (rather than actually testing platform-specific data types). Next stepsOn my side, I've created an issue in dbt-core to add functional tests for the Could you raise an issue in dbt-spark as well? Once the fix is merged, dbt-databricks will inherit it. |
This issue has been marked as Stale because it has been open for 180 days with no activity. If you would like the issue to remain open, please comment on the issue or else it will be closed in 7 days. |
Nope |
@rlh1994 I just removed the |
Is this your first time submitting a feature request?
Describe the feature
Currently the core dbt
api.Column.string_type
is not overwritten, however the default value is not suitable for bigquery data types, which I believe only supports thestring
type.Describe alternatives you've considered
Using
dbt.type_string
, but this isn't suitable in all usecases, see here dbt-labs/dbt-core#7103Who will this benefit?
Cross-warehouse users.
Are you interested in contributing this feature?
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: