snowflakedb / gosnowflake

Go Snowflake Driver
Apache License 2.0
285 stars 116 forks source link

[bug fix] objectType should work w/ or wo/ ENABLE_STRUCTURED_TYPES_IN_CLIENT_RESPONSE #1134

Closed madisonchamberlain closed 2 months ago

madisonchamberlain commented 2 months ago

Description

If we get a snowflake object type, but we haven't set the flag ENABLE_STRUCTURED_TYPES_IN_CLIENT_RESPONSE, the code will panic because we are only setting the record on the batch if the snowflake type matches the expected arrow type. This will add support for the underlying type to be either structured or string for snowflake objectType, and if its neither, we will return an error with the underlying type rather than panic so we can fix it

Checklist

madisonchamberlain commented 2 months ago

I cant get this to correctly rebase off my fork so I moved it all here https://github.com/snowflakedb/gosnowflake/pull/1137

madisonchamberlain commented 2 months ago

Closed in favor of https://github.com/snowflakedb/gosnowflake/pull/1137