-
-
Notifications
You must be signed in to change notification settings - Fork 23
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
Updatable server-side scrollable cursor reports wrong size when inserting a row through the result set before fetching #819
Comments
To be frontported to Jaybird 6 |
As bonus, the fix does away with some complexity in the fetcher. In the original implementation, I delayed knowing the server-side (and local) cursor size until absolutely necessary, but that involved some gnarly logic in places. |
I spoke too soon. There is actually a good reason for the convoluted logic. Avoiding the need to know the cursor size ahead of time conserves server resources by not materializing the entire result set. |
…when inserting a row through the result set before fetching
…e cursor reports wrong size when inserting a row through the result set before fetching
While investigating #818, I noticed that the server-side scrollable cursor implementation reported the wrong size if I inserted a row through the result set immediately after execute (thus without fetching any rows), and the inserted row was included twice in the result set: once server-side, and once locally.
This happens because the cursor is not materialized server-side until the first fetch, and so the inserted row was materialized in the server-side cursor, and also stored in the local "inserted rows" list, and thus reported twice. We need to address this by forcing materialization of the cursor earlier, maybe immediately on creating the fetcher.
The text was updated successfully, but these errors were encountered: