GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Support pyarrow.large_* as column type in dataframe upload/ download · Issue #15716 · googleapis/google-cloud-python

Support pyarrow.large_* as column type in dataframe upload/ download #15716

New issue
Copy link
New issue
Copy link
Closed as not planned
Closed as not planned
Support pyarrow.large_* as column type in dataframe upload/ download#15716
Copy link
Assignees
vchudnov-g
Labels
api: bigqueryIssues related to the BigQuery API.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Description

@cvm-a
cvm-a
opened on Oct 30, 2023
Issue body actions

Thanks for stopping by to let us know something could be better!

PLEASE READ: If you have a support contract with Google, please create an issue in the support console instead of filing on GitHub. This will ensure a timely response.

Is your feature request related to a problem? Please describe.

  1. (P1 because it's so simple) When uploading a dataframe, I get a Pyarrow could not determine the type of columns" warning raised with with pyarrow.large_string() columns. this should be a trivial addition in _ARROW_SCALAR_IDS_TO_BQ.
  2. (P2 because it takes longer to fix ) When downloading results can we support ( maybe even default to using) pyarrow.large_string ( and other pyarrow.large(*) instead of pyarrow.string for
    QueryJob.to_arrow. pyarrow.string has a 2GiB limit on the size of the data in the column (not just in a single element) that's guaranteed to work correctly. If query results are bigger, they might not immediately break because the data is usually chunked smaller, but many dataframe operations ( like aggregations or even indexing) on these columns trigger a "ArrowInvalid: offset overflow" error. This is mainly caused by bad decisions in Arrow ([C++][Python] Large strings cause ArrowInvalid: offset overflow while concatenating arrays apache/arrow#33049), but we can try to keep BQ users safe. The performance/ memory hit has usually been small, and 2GiB is very easy to cross.

Describe the solution you'd like

  1. add pyarrow.large_* keys to _ARROW_SCALAR_IDS_TO_BQ
  2. add an option or default to return large_* types in QueryJob.to_arrow

Describe alternatives you've considered
For 2, I have converted the string columns to large_string myself immediately after loading, and it has not triggered issues yet, but the Arrow API does not seem to guarantee that this should continue to work.
Additional context

Reacted by Aaron Keesing

Activity

  1. product-auto-label
    added
    api: bigqueryIssues related to the BigQuery API.
    on Oct 30, 2023
  2. Linchin
    added
    type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.
    on Oct 31, 2023
  3. Gaurang033 commented on Dec 15, 2023

    @Gaurang033
    Gaurang033
    on Dec 15, 2023
    Contributor
    More actions

    @Linchin does bigquery able to handle more than 2 GB of data in a single cell ?

  4. cvm-a commented on Dec 19, 2023

    @cvm-a
    cvm-a
    on Dec 19, 2023 via email
    Author
    More actions
    The 2GB limit is for the entire column in the Arrow table, since internally the string arrays are effectively just one long string, with the elements delimited by their offsets
    …
    On Fri, Dec 15, 2023 at 7:01 AM Gaurang Shah ***@***.***> wrote: @Linchin <https://github.com/Linchin> does bigquery able to handle more than 2 GB of data in a single cell ? — Reply to this email directly, view it on GitHub <#15716 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/A7RK7XFUZCB2K3NMG4N5HXDYJRQ4FAVCNFSM6AAAAAA6WURMLGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNJYGAZDANBZGI> . You are receiving this because you authored the thread.Message ID: ***@***.***>
  5. Linchin commented on Feb 3, 2024

    @Linchin
    Linchin
    on Feb 3, 2024
    Contributor
    More actions

    There are max cell size for CSV and JSON, but there's no mentioning of other formats (except for total file size < 15TB). I suppose that means there's no limit?

  6. parthea commented on Jan 12, 2026

    @parthea
    parthea
    on Jan 12, 2026
    Contributor
    More actions

    Transferring to google-cloud-python as the code for python-bigquery will be migrated there in 1-3 weeks.

  7. parthea
    transferred this issue fromgoogleapis/python-bigqueryon Jan 12, 2026
  8. parthea commented on Jan 12, 2026

    @parthea
    parthea
    on Jan 12, 2026
    Contributor
    More actions

    Transferring this issue back to python-bigquery.

  9. parthea
    transferred this issue fromgoogleapis/google-cloud-pythonon Jan 12, 2026
  10. blunderbuss-gcf
    assigned
    vchudnov-g
    on Jan 12, 2026
  11. chalmerlowe commented on Mar 2, 2026

    @chalmerlowe
    chalmerlowe
    on Mar 2, 2026
    Contributor
    More actions

    This issue was moved from the following repo as part of the monorepo migration: googleapis/python-bigquery

  12. chalmerlowe
    transferred this issue fromgoogleapis/python-bigqueryon Mar 2, 2026
  13. daniel-sanche commented on May 28, 2026

    @daniel-sanche
    daniel-sanche
    on May 28, 2026
    Contributor
    More actions

    This issue is being bulk closed due to inactivity. Please re-open if you think this still requires attention, and we'll take another look. Thanks!

  14. daniel-sanche
    closed this as not plannedon May 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @vchudnov-g
    vchudnov-g

Labels

api: bigqueryIssues related to the BigQuery API.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.