-
Notifications
You must be signed in to change notification settings - Fork 32
expose PQsetChunkedRowsMode #79
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
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to see test added
I added in 85747d2 , hopefully all good |
| ntuples r3 >>= assertEqual "singlerow 3" 1 | ||
| Just r4 <- getResult conn | ||
| ntuples r4 >>= assertEqual "singlerow eof" 0 | ||
| getResult conn >>= assertEqual "singlerow end" Nothing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I decided to be a bit more verbose here (e.g. the shouldReturn use above unfortunately squishes the info about failed tests to a single line of code and single test name, this allows better debugging).
I can minify the getResult cascade code to a single zipWithM if required.
|
@phadej mild bump here. |
Hello,
essentially this is exposing the other function from the two here https://www.postgresql.org/docs/current/libpq-single-row-mode.html , which enable row streaming for looong queries.
The PR is quite straightforward so I'm not sure if much commentary is needed. I hope the C type mapping is OK. The wider context is that we'd really like to have it for continuing the work on valderman/selda#200 .
Thanks!
-mk
(cc @benjaminweb)