-
Notifications
You must be signed in to change notification settings - Fork 175
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
Change how a column of type VECTOR is parsed #1169
base: main
Are you sure you want to change the base?
Conversation
Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Andrew Hawkins.
|
Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Andrew Hawkins.
|
@achawkins this looks pretty merge-able, are you able to sign our CLA and add a changelog? |
Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Andrew Hawkins.
|
@colin-rogers-dbt I must have signed the CLA with a different email before. I resigned it and added the changelog entry. |
@cla-bot check |
Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Andrew Hawkins.
|
The cla-bot has been summoned, and re-checked this pull request! |
can this be merged? blocking us from moving forward |
Is there any update on this PR status? |
resolves #1098
docs dbt-labs/docs.getdbt.com/#
Problem
When an incremental (maybe other materializations, but I have not checked) model with a
VECTOR
type is run, it will fail to create theSnowflakeColumn
object from thefrom_description
class method. This is because thedbt-adapters
Column.from_description
method does some parsing to extract the precision and scale of a numeric type and tries to cast both values within parenthesis to integers. The Snowflake vector is of the formVECTOR(<data_type>, <dimension>)
, so the<data_type>
will fail to be cast as an integer.Solution
If the data type has the word
VECTOR
in it, bypass the additional parsing done indbt-adapters
and return aSnowflakeColumn
that uses the raw data type as the parsed data type. If it does not, then pass it through to the defaultfrom_description
method.Checklist