1
0
mirror of https://github.com/MariaDB/server.git synced 2025-09-11 05:52:26 +03:00

BUG#50312 Warnings for unsafe sub-statement not returned to client

After BUG#36649, warnings for sub-statements are cleared when a 
new sub-statement is started. This is problematic since it suppresses
warnings for unsafe statements in some cases. It is important that we
always give a warning to the client, because the user needs to know
when there is a risk that the slave goes out of sync.
                        
We fixed the problem by generating warning messages for unsafe statements
while returning from a stored procedure, function, trigger or while
executing a top level statement.
                        
We also started checking unsafeness when both performance and log tables are
used. This is necessary after the performance schema which does a distinction
between performance and log tables.
This commit is contained in:
Alfranio Correia
2010-08-10 12:32:54 +01:00
parent 89ad5fa810
commit bd3aa7eb78
17 changed files with 782 additions and 1259 deletions

View File

@@ -468,6 +468,7 @@ BEGIN
END|
DELIMITER ;|
--echo "One unsafe warning should be issued in the following statement"
--error ER_STORED_FUNCTION_PREVENTS_SWITCH_SQL_LOG_BIN
SELECT fun_check_log_bin();
--echo "SQL_LOG_BIN should be ON still"
SHOW VARIABLES LIKE "SQL_LOG_BIN";