Skip to content

Conversation

chelsea-lin
Copy link
Contributor

@chelsea-lin chelsea-lin commented Apr 18, 2025

This PR expands the functionality of the index_col parameter in the read_csv method.

New capabilities include:

  1. Multi-column Indexing: index_col now accepts an iterable of strings (column names) to create a MultiIndex. (Fixes internal issue 338089659)
  2. Integer Indexing: Support for a single integer index or an iterable of integers (column positions) is also explicitly included/verified. (Fixes internal issue 404530013)
  3. Pandas Compatibility: Adds tests to ensure that the behavior of index_col when set to False, None, or True aligns with standard Pandas behavior. (Fixes internal issue 338400133)

@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Apr 18, 2025
@chelsea-lin chelsea-lin force-pushed the main_chelsealin_readcsv_index_col branch from 856ba44 to 94b3fb6 Compare April 18, 2025 16:42
@chelsea-lin chelsea-lin changed the title feat: support an integer and an iterable of integers for index_col parameter of read_csv feat: enhance read_csv index_col parameter support Apr 18, 2025
@chelsea-lin chelsea-lin force-pushed the main_chelsealin_readcsv_index_col branch from 94b3fb6 to bbda15e Compare April 18, 2025 18:10
@chelsea-lin chelsea-lin marked this pull request as ready for review April 18, 2025 18:30
@chelsea-lin chelsea-lin requested review from a team as code owners April 18, 2025 18:30
@chelsea-lin chelsea-lin requested a review from shuoweil April 18, 2025 18:30
@chelsea-lin chelsea-lin added the owlbot:run Add this label to trigger the Owlbot post processor. label Apr 18, 2025
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Apr 18, 2025
@chelsea-lin chelsea-lin enabled auto-merge (squash) April 18, 2025 21:46
@chelsea-lin chelsea-lin merged commit f4e5b26 into main Apr 18, 2025
24 checks passed
@chelsea-lin chelsea-lin deleted the main_chelsealin_readcsv_index_col branch April 18, 2025 21:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants