1# Tests for PERFORMANCE_SCHEMA 2# Make sure mysql_upgrade does not destroy data in a 'performance_schema' 3# database. 4# 5 6--source include/not_embedded.inc 7--source include/have_perfschema.inc 8 9# Some initial settings + Preemptive cleanup 10let $MYSQLD_DATADIR= `SELECT @@datadir`; 11let $err_file= $MYSQLTEST_VARDIR/tmp/pfs_upgrade_proc.err; 12let $out_file= $MYSQLTEST_VARDIR/tmp/pfs_upgrade_proc.out; 13--error 0,1 14--remove_file $out_file 15--error 0,1 16--remove_file $err_file 17 18--disable_warnings 19drop procedure if exists test.user_proc; 20--enable_warnings 21 22--echo "Testing mysql_upgrade with PROCEDURE performance_schema.user_proc" 23 24create procedure test.user_proc() 25 select "Not supposed to be here"; 26 27update mysql.proc set db='performance_schema' where name='user_proc'; 28 29--source suite/perfschema/include/upgrade_check.inc 30 31select name from mysql.proc where db='performance_schema'; 32 33update mysql.proc set db='test' where name='user_proc'; 34drop procedure test.user_proc; 35