Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix RowDocumentIterator's hasNext implementation. #1615

Closed
wants to merge 2 commits into from

Conversation

schauder
Copy link
Contributor

This properly fixes the test setup, taking into account that @ActiveProfile by default replaces any profiles set via environment variable or system property.
It turns out that the hasNext calculation in RowDocumentIterator was wrong because

a) isBeforeFirst and isBeforeLast return both false when the ResultSet is empty.
b) isBeforeFirst and isBeforeLast aren't necessarily implemented for all ResultSets and for example DB2s ResultSet implementation don't support it by default.

This properly fixes the test setup, taking into account that @ActiveProfile by default replaces any profiles set via environment variable or system property.
It turns out that the hasNext calculation in RowDocumentIterator was wrong because

a) isBeforeFirst and isBeforeLast return both false when the ResultSet is empty.
b) isBeforeFirst and isBeforeLast aren't necessarily implemented for all ResultSets and for example DB2s ResultSet implementation don't support it by default.
@schauder schauder force-pushed the issue/fix-RowDocumentResultSetExtractor branch from 5d6ce18 to 929c124 Compare September 19, 2023 12:04
@mp911de mp911de added the type: bug A general bug label Sep 20, 2023
@mp911de mp911de added this to the 3.2 RC1 (2023.1.0) milestone Sep 20, 2023
@mp911de mp911de closed this in bc644aa Sep 20, 2023
mp911de added a commit that referenced this pull request Sep 20, 2023
Tweak naming. Refine methods to static ones and collapse into a single method.

See #1615
@mp911de mp911de deleted the issue/fix-RowDocumentResultSetExtractor branch September 20, 2023 07:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants