Skip to content

fix(jdbc): read column metadata left to right - #65

Merged
stbischof merged 1 commit into
mainfrom
fix/columns-read-in-order
Oct 16, 2026
Merged

stbischof merged 1 commit into
mainfrom
fix/columns-read-in-order

Conversation

@stbischof

Copy link
Copy Markdown
Contributor

jdbc: read column metadata left to right

DatabaseServiceImpl.createMetaInfo fails on Oracle with ORA-17027: Stream has already been closed.
getColumns returns COLUMN_DEF (column 13) as a LONG stream; reading CHAR_OCTET_LENGTH (16) before it
consumes the stream. The loop now reads the columns in their getColumns order, as JDBC asks of a portable reader.

Test: DatabaseServiceReadsColumnsInOrderTest — H2 behind a result set that keeps Oracle's LONG rule; red before the fix.

Oracle returns COLUMN_DEF as a LONG stream; reading a later column first
fails with ORA-17027.

Signed-off-by: Stefan Bischof <stbischof@bipolis.org>
@stbischof
stbischof merged commit 1832624 into main Oct 16, 2026
31 of 32 checks passed
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.

1 participant