DB-API depends on pyarrow when decimal query parameters are used #549
Labels
priority: p2
Moderately-important priority. Fix may not be included in next release.
type: bug
Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
It seems we introduced a hard dependency on pyarrow to detect data types of query parameters in the DB-API module. While
pyarrow
is recommended as it's needed to use the BigQuery Storage API, I don't think we want to depend on it for basic functionality.I believe we added this hard dependency here: https://github.com/googleapis/python-bigquery/pull/527/files#diff-2221cd9b6b85f2ed1f943c474e8a8628e6ca28ec9a96c0aa5873cd6a66826bdeR193
We use
pyarrow
to disambiguate betweenNUMERIC
andBIGNUMERIC
. I'm not seeing a good way to check the precision / scale in the decimal type, so in the case thatpyarrow
is not available, we should guess the type isNUMERIC
.Stack trace
The text was updated successfully, but these errors were encountered: