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

affected_row_count should be implemented for all executed statements (including Prepared) #107

Open
jpastuszek opened this issue Feb 21, 2019 · 0 comments

Comments

@jpastuszek
Copy link
Contributor

Currently affected_row_count method is available for direct query (Allocated/Executed) and Prepared with HasResult but not for prepared query with NoResult.
If you run INSERT via prepared query you can't get the number of affected rows.

This looks all wrong to me though... Executed is an alias Allocated so you can't distinguish based on this on type system level. Also Prepared has no concept of Executed so you can only work with HasResult/NoResult on type system level. Ideally you could add another type parameter and have two pairs Direct/Prepared and Allocated/Executed so that you can implement affected_row_count to any type that is Executed and change Executed to Allocated with close_cursor method.

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

No branches or pull requests

1 participant