Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
3.1.11
-
None
-
None
Description
While working on implementation of the task MDEV-16708 I've got stumble with the following issue: warnings generated during execution of the CALL is not displayed in case the binary protocol is used for communication between client and server.
I pushed the branch 10.6-MDEV-16708 that adds support for execution of some formerly missed statements in prepared statement mode including the CALL statement. If run a server built with this patch then the following test case will reproduce the issue.
$ cat mysql-test/main/ps_ps.test
create procedure proc_1() checksum table xyz;
call proc_1();
SHOW WARNINGS;
drop procedure proc_1;
$ ./mtr --ps-protocol main.ps_ps
create procedure proc_1() checksum table xyz;
call proc_1();
Table Checksum
test.xyz NULL
SHOW WARNINGS;
Level Code Message
Error 1146 Table 'test.xyz' doesn't exist
drop procedure proc_1;
If the same test is run without the option --ps-protocol
the test output is the following:
$ ./mtr main.ps_ps
create procedure proc_1() checksum table xyz;
call proc_1();
Table Checksum
test.xyz NULL
Warnings:
Error 1146 Table 'test.xyz' doesn't exist
SHOW WARNINGS;
Level Code Message
Error 1146 Table 'test.xyz' doesn't exist
drop procedure proc_1;
As you can seen the warning message
Error 1146 Table 'test.xyz' doesn't exist
is not output as a result of the statement execution in case the CALL statement
is run via PS protocol although explicit execution of the SHOW WARNING statement
results in displaying warning details.