[python] Fix/scalar global index search mode default#8844
Draft
XiaoHongbo-Hope wants to merge 2 commits into
Draft
[python] Fix/scalar global index search mode default#8844XiaoHongbo-Hope wants to merge 2 commits into
XiaoHongbo-Hope wants to merge 2 commits into
Conversation
XiaoHongbo-Hope
force-pushed
the
fix/scalar-global-index-search-mode-default
branch
4 times, most recently
from
July 24, 2026 11:28
d0b4849 to
4eefdda
Compare
…nt row loss Scalar (sorted/bitmap) global-index queries used the vector/full-text `global-index.search-mode` = fast, which returns no unindexed ranges, so rows committed but not yet covered by the index were pruned before being read and `WHERE <indexed_col> = X` silently returned incomplete results. - Add `scalar-index.search-mode` (default `full`). Resolution priority: explicit `scalar-index.search-mode` -> an explicit `global-index.search-mode` (inherited) -> default `full`. - Thread an optional `search_mode` through DataEvolutionGlobalIndexCoverage and DataEvolutionGlobalIndexScanner.unindexed_rows. - Only the pure scalar scan (file_scanner) passes the scalar mode. Vector / full-text callers leave it unset and keep the fast default, so a vector scan with a scalar filter is not widened into a full-table brute-force scan.
…rrowNotImplementedError Reading a projected VARIANT column (struct<value, metadata>) from a Parquet file with multiple row groups failed with "Nested data conversions not implemented for chunked array outputs": a single dataset scanner assembles the nested column across row groups (and pages) into one ChunkedArray, which is unimplemented. For a multi-row-group Parquet file with a projected VARIANT column, FormatPyArrowReader reads row groups via ParquetFile (which avoids that assembly), keeping: - column pruning: reads only projected columns plus filter-only columns, which are threaded from SplitRead and dropped from the result after filtering; - row-group pruning: excludes row groups by statistics via fragment metadata; - predicate: applied per row group through an in-memory dataset scanner, not Table.filter(Expression) (rejected by older PyArrow). The ParquetFile is opened via the filesystem's file handle rather than the `filesystem=` kwarg (unsupported on PyArrow 6.0.1). Scalar-only / single-row-group reads keep the original whole-file scanner. Verified on PyArrow 19.0.1 against a real 140 MB / 2-row-group table.
XiaoHongbo-Hope
force-pushed
the
fix/scalar-global-index-search-mode-default
branch
from
July 24, 2026 11:53
4eefdda to
fb38ba0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Tests