Skip to content

fix(snowflake): request microsecond timestamps when fetching Arrow data - #12155

Closed
nil68657 wants to merge 1 commit into
ibis-project:mainfrom
nil68657:fix-snowflake-microsecond-arrow
Closed

nil68657 wants to merge 1 commit into
ibis-project:mainfrom
nil68657:fix-snowflake-microsecond-arrow

Conversation

@nil68657

Copy link
Copy Markdown

Description of changes

The connector picks each Arrow batch's timestamp unit from its values,
so one result can mix timestamp[ns] and timestamp[us] batches and
to_pyarrow_batches/to_polars fail to combine them. Pass
force_microsecond_precision=True to fetch_arrow_batches and
fetch_arrow_all (to_pyarrow, to_pyarrow_batches and execute) when the
installed connector accepts it; older connectors keep their current
behaviour.

Digits below the microsecond on TIMESTAMP(9) columns are dropped, the
trade-off agreed on in the issue.

Issues closed

This PR is a joint contribution from Nilanjan Chatterjee and Claude (Claude Opus 5.5, via Claude Code). Nilanjan chose the issue and directed the work; Claude reproduced the problem, wrote the change, its tests and this description.

Authored by Nilanjan Chatterjee (@nil68657).

The connector picks each Arrow batch's timestamp unit from its values,
so one result can mix timestamp[ns] and timestamp[us] batches and
to_pyarrow_batches/to_polars fail to combine them. Pass
force_microsecond_precision=True to fetch_arrow_batches and
fetch_arrow_all (to_pyarrow, to_pyarrow_batches and execute) when the
installed connector accepts it; older connectors keep their current
behaviour.

Digits below the microsecond on TIMESTAMP(9) columns are dropped, the
trade-off agreed on in the issue.

Fixes ibis-project#11983

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added tests Issues or PRs related to tests snowflake The Snowflake backend labels Oct 11, 2026
@deepyaman deepyaman added the maybe-ai Apply to low-effort autonomous PRs to automatically close them. label Oct 12, 2026
@github-actions

Copy link
Copy Markdown
Contributor

This was marked as potentially AI generated and will be closed now. If this is an error, please provide additional details, make sure to read the docs about contributing and AI.

@github-actions github-actions Bot closed this Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maybe-ai Apply to low-effort autonomous PRs to automatically close them. snowflake The Snowflake backend tests Issues or PRs related to tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: ibis-framework: Snowflake backend should pass force_microsecond_precision=True

2 participants