Skip to content

Return false when array result cursors move out of bounds - #912

Merged
staticlibs merged 1 commit into
duckdb:mainfrom
hutiefang76:frank/newten-dd-array-cursor-20261010-01a11186
Oct 10, 2026
Merged

staticlibs merged 1 commit into
duckdb:mainfrom
hutiefang76:frank/newten-dd-array-cursor-20261010-01a11186

Conversation

@hutiefang76

Copy link
Copy Markdown
Contributor

Array-backed ResultSet navigation currently reports success at before-first and after-last sentinels, including on empty arrays. The fix returns false outside actual rows, reports getRow() as zero off a row, and keeps empty-result position predicates false. Regression coverage exercises absolute, relative, next and previous navigation and verifies element values.

Validation on macOS arm64: compiled all Java production and test sources against the existing JNI artifact; ran test_array (2 tests). New regressions fail against the original Java implementation and pass with this patch. The full official clang-format 11 check passes. Full native and multi-platform CI remain to be run.

AI assistance was used for implementation and source review.

Signed-off-by: hutiefang76 <137664623+hutiefang76@users.noreply.github.com>

@staticlibs staticlibs left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! Looks good to me.

@staticlibs
staticlibs merged commit 050a041 into duckdb:main Oct 10, 2026
31 of 32 checks passed
staticlibs pushed a commit that referenced this pull request Oct 10, 2026
This is a backport of the PR #912 to `v2.0-cyanoptera` branch.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants