BigQuery: Support user-overridable dtypes in to_dataframe
method.
#7049
Labels
api: bigquery
Issues related to the BigQuery API.
type: feature request
‘Nice-to-have’ improvement, new feature or different behavior or design.
With pandas 0.24.0 (unreleased), a new dtype is available to support nullable integer columns. http://pandas-docs.github.io/pandas-docs-travis/integer_na.html#integer-na The default behavior is to convert to float, but this can result in data loss (#6177). This new dtype extension avoids that.
I propose we allow the user to provide a map from column names to dtypes for any columns for which they'd like to override the default behavior. This argument could be called
dtype_overrides
. This would also be useful for other extension dtypes in the future, such as for GEOGRAPHY columns.See googleapis/python-bigquery-pandas#242 for additional discussion.
Alternatives
The text was updated successfully, but these errors were encountered: