Fix #41997: SP call yields additional empty result set#4496
Fix #41997: SP call yields additional empty result set#4496cmb69 wants to merge 1 commit intophp:PHP-7.2from
Conversation
When stored procedures are called, the "final result set is a status result that includes no result set". Calling `::nextRowset()` on the actual last result set should return FALSE, since there is actually no further result set to be processed.
|
@andreyhristov, @johannes, could you please review? |
|
If I recally correctly, it was up to the extension (not mysqlnd) to read the last result set from a SP call and decide what to do. The idea is that a SP can create more info, not just the status. Depending on the level at which the API (mysqli or PDO) works the behavior could be different, thus mysqlnd is agnostic. |
|
Thanks for the explanation. This PR is for pdo_mysql, though (not mysqlnd). :) |
|
I was looking at the comments in the bug tracker and there there is a comment: BTW, my opinion is more or less that libmysqlclient support should be dropped. Yes, it is the reference library but if you look how many tests fail with it and don't with mysqlnd. I would not put a code in production that uses mysqli/pdo on top of libmysqlclient. |
|
@andreyhristov, that was a comment while working on that bug; the following comment clarified that libmysql-client works the same, what led to this PR targeting pdo_mysql. |
|
ok :) |
|
|
Applied as 41a4379. Thanks. |
When stored procedures are called, the "final result set is a status
result that includes no result set". Calling
::nextRowset()on theactual last result set should return FALSE, since there is actually no
further result set to be processed.