Bug #86119 | SERVER_PS_OUT_PARAMS not set with prepared call statement | ||
---|---|---|---|
Submitted: | 27 Apr 2017 19:27 | Modified: | 11 May 2017 13:31 |
Reporter: | John Dow | Email Updates: | |
Status: | Duplicate | Impact on me: | |
Category: | MySQL Server: C API (client library) | Severity: | S3 (Non-critical) |
Version: | 5.7.18 | OS: | Debian |
Assigned to: | CPU Architecture: | Any |
[27 Apr 2017 19:27]
John Dow
[11 May 2017 8:50]
Chiranjeevi Battula
Hello John Dow, Thank you for the bug report. This is most likely duplicate of Bug #79662, please see Bug #79662. Thanks, Chiranjeevi.
[11 May 2017 13:31]
John Dow
Hello Chiranjeevi, I "do not have access to bug #79662."
[29 Aug 2023 19:02]
Rene' Cannao'
John, SERVER_PS_OUT_PARAMS is never sent if CLIENT_DEPRECATE_EOF capability flag is set (since MySQL 5.7.5). If CLIENT_DEPRECATE_EOF is NOT set (see https://dev.mysql.com/doc/dev/mysql-server/latest/group__group__cs__capabilities__flags.ht...) a resultset has: * a packet with column_count * column_count packets with column definition * a first EOF packet * a packet for each row in the resultset * a second EOF packet If CLIENT_DEPRECATE_EOF is set, the first EOF is not sent, and the second EOF is replaced with an OK packet. The problem? SERVER_PS_OUT_PARAMS is sent in the first EOF only. Therefore, because CLIENT_DEPRECATE_EOF disables the first EOF packet, SERVER_PS_OUT_PARAMS is never sent. References using MySQL 8.0.33 as an example (other versions have the same issue): https://github.com/mysql/mysql-server/blob/mysql-8.0.33/sql/protocol_classic.cc#L300-L307 https://github.com/mysql/mysql-server/blob/mysql-8.0.33/sql/protocol_classic.cc#L3686-L370... In other words, CLIENT_DEPRECATE_EOF is incompatible with SERVER_PS_OUT_PARAMS . This makes the documentation on https://dev.mysql.com/doc/c-api/8.0/en/c-api-prepared-call-statements.html incorrect since MySQL 5.7.5 .