Skip to content

GH-1523: NullPointerException when executing executeUpdate method and the backend returns -1 - #1524

Open
scruz-denodo wants to merge 1 commit into
apache:mainfrom
scruz-denodo:execute_update_zero
Open

scruz-denodo wants to merge 1 commit into
apache:mainfrom
scruz-denodo:execute_update_zero

Conversation

@scruz-denodo

Copy link
Copy Markdown

What's Changed

Result from the executeUpdate method is checked at org.apache.arrow.driver.jdbc.client.ArrowFlightSqlClientHandler.
The returned value is always greater or equals to zero.

So, in the practice, a negative number of updated records is normalized to zero.

Tests

Added test for PreparedStatement and Statement at ArrowFlightPreparedStatementTest and ArrowFlightStatementExecuteTest

…od and the backend returns -1

A server that does not know how many rows an update changed answers -1. Avatica takes that for a statement that
returned a result set, and fails with a NullPointerException because the
signature of an update has no columns. The driver now reports 0.
@scruz-denodo scruz-denodo changed the title GH-1523: NullPointerException when executing executeUpdate method a… GH-1523: NullPointerException when executing executeUpdate method and the backend returns -1 Nov 25, 2026
@scruz-denodo

Copy link
Copy Markdown
Author

This change is for #1523 issue

@jbonofre jbonofre added the bug-fix PRs that fix a big. label Nov 25, 2026
@apache apache deleted a comment from github-actions Bot Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug-fix PRs that fix a big.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants