Loading mysql-test/include/get_binlog_dump_thread_id.inc 0 → 100644 +9 −0 Original line number Diff line number Diff line --exec $MYSQL test -e 'show processlist' | grep 'Binlog Dump' | cut -f1 > $MYSQLTEST_VARDIR/tmp/bl_dump_thread_id --disable_warnings drop table if exists t999; --enable_warnings create temporary table t999 (f int); --replace_result $MYSQLTEST_VARDIR "." eval LOAD DATA INFILE "$MYSQLTEST_VARDIR/tmp/bl_dump_thread_id" into table t999; let $id = `select f from t999`; drop table t999; mysql-test/lib/mtr_process.pl +2 −3 Original line number Diff line number Diff line Loading @@ -465,8 +465,7 @@ sub mtr_kill_leftovers () { if ( kill(0, @pids) ) # Check if some left { # FIXME maybe just mtr_warning() ? mtr_error("can't kill process(es) " . join(" ", @pids)); mtr_warning("can't kill process(es) " . join(" ", @pids)); } } } Loading @@ -479,7 +478,7 @@ sub mtr_kill_leftovers () { { if ( mtr_ping_mysqld_server($srv->{'port'}, $srv->{'sockfile'}) ) { mtr_error("can't kill old mysqld holding port $srv->{'port'}"); mtr_warning("can't kill old mysqld holding port $srv->{'port'}"); } } } Loading mysql-test/mysql-test-run.pl +9 −0 Original line number Diff line number Diff line Loading @@ -312,6 +312,9 @@ our $opt_udiff; our $opt_skip_ndbcluster; our $opt_with_ndbcluster; our $opt_with_ndbcluster_only= 0; # dummy, ignored our $opt_with_openssl; our $exe_ndb_mgm; our $path_ndb_tools_dir; Loading Loading @@ -572,6 +575,7 @@ sub command_line_setup () { 'force' => \$opt_force, 'with-ndbcluster' => \$opt_with_ndbcluster, 'skip-ndbcluster|skip-ndb' => \$opt_skip_ndbcluster, 'with-ndbcluster-only' => \$opt_with_ndbcluster_only, 'do-test=s' => \$opt_do_test, 'suite=s' => \$opt_suite, 'skip-rpl' => \$opt_skip_rpl, Loading Loading @@ -677,6 +681,11 @@ sub command_line_setup () { print '#' x 78, "\n\n"; } if ( $opt_with_ndbcluster_only ) { print "# Option '--with-ndbcluster-only' is ignored in this release.\n"; } foreach my $arg ( @ARGV ) { if ( $arg =~ /^--skip-/ ) Loading mysql-test/mysql-test-run.sh +12 −0 Original line number Diff line number Diff line Loading @@ -277,6 +277,7 @@ EXTRA_MYSQLSHOW_OPT="" EXTRA_MYSQLBINLOG_OPT="" USE_RUNNING_SERVER=0 USE_NDBCLUSTER=@USE_NDBCLUSTER@ USE_NDBCLUSTER_ONLY=0 USE_RUNNING_NDBCLUSTER="" USE_PURIFY="" PURIFY_LOGS="" Loading Loading @@ -315,6 +316,8 @@ STRESS_INIT_FILE="" STRESS_TEST_FILE="" STRESS_TEST="" $ECHO "Logging: $0 $*" # To ensure we see all arguments in the output, for the test analysis tool while test $# -gt 0; do case "$1" in --embedded-server) Loading @@ -341,6 +344,10 @@ while test $# -gt 0; do --extern) USE_RUNNING_SERVER=1 ;; --with-ndbcluster) USE_NDBCLUSTER="--ndbcluster" ;; --with-ndbcluster-only) USE_NDBCLUSTER="--ndbcluster" USE_NDBCLUSTER_SLAVE="--ndbcluster" USE_NDBCLUSTER_ONLY=1 ;; --ndb-connectstring=*) USE_NDBCLUSTER="--ndbcluster" ; USE_RUNNING_NDBCLUSTER=`$ECHO "$1" | $SED -e "s;--ndb-connectstring=;;"` ;; Loading Loading @@ -1654,6 +1661,11 @@ run_testcase () result_file="r/$tname.result" echo $tname > $CURRENT_TEST SKIP_SLAVE=`$EXPR \( $tname : rpl \) = 0 \& \( $tname : federated \) = 0` NDBCLUSTER_TEST=`$EXPR \( $tname : '.*ndb.*' \) != 0` if [ "x$USE_NDBCLUSTER_ONLY" = "x1" -a "x$NDBCLUSTER_TEST" != "x1" ] ; then skip_test $tname return fi if [ "$USE_MANAGER" = 1 ] ; then many_slaves=`$EXPR \( \( $tname : rpl_failsafe \) != 0 \) \| \( \( $tname : rpl_chain_temp_table \) != 0 \)` fi Loading mysql-test/r/having.result +35 −0 Original line number Diff line number Diff line Loading @@ -359,3 +359,38 @@ group by s1 collate latin1_swedish_ci having s1 = 'y'; s1 count(s1) y 1 drop table t1; DROP SCHEMA IF EXISTS HU; Warnings: Note 1008 Can't drop database 'HU'; database doesn't exist CREATE SCHEMA HU ; USE HU ; CREATE TABLE STAFF (EMPNUM CHAR(3) NOT NULL UNIQUE, EMPNAME CHAR(20), GRADE DECIMAL(4), CITY CHAR(15)); CREATE TABLE PROJ (PNUM CHAR(3) NOT NULL UNIQUE, PNAME CHAR(20), PTYPE CHAR(6), BUDGET DECIMAL(9), CITY CHAR(15)); INSERT INTO STAFF VALUES ('E1','Alice',12,'Deale'); INSERT INTO STAFF VALUES ('E2','Betty',10,'Vienna'); INSERT INTO STAFF VALUES ('E3','Carmen',13,'Vienna'); INSERT INTO STAFF VALUES ('E4','Don',12,'Deale'); INSERT INTO STAFF VALUES ('E5','Ed',13,'Akron'); INSERT INTO PROJ VALUES ('P1','MXSS','Design',10000,'Deale'); INSERT INTO PROJ VALUES ('P2','CALM','Code',30000,'Vienna'); INSERT INTO PROJ VALUES ('P3','SDP','Test',30000,'Tampa'); INSERT INTO PROJ VALUES ('P4','SDP','Design',20000,'Deale'); INSERT INTO PROJ VALUES ('P5','IRM','Test',10000,'Vienna'); INSERT INTO PROJ VALUES ('P6','PAYR','Design',50000,'Deale'); SELECT EMPNUM, GRADE*1000 FROM HU.STAFF WHERE GRADE * 1000 > ANY (SELECT SUM(BUDGET) FROM HU.PROJ GROUP BY CITY, PTYPE HAVING HU.PROJ.CITY = HU.STAFF.CITY); EMPNUM GRADE*1000 E3 13000 DROP SCHEMA HU; Loading
mysql-test/include/get_binlog_dump_thread_id.inc 0 → 100644 +9 −0 Original line number Diff line number Diff line --exec $MYSQL test -e 'show processlist' | grep 'Binlog Dump' | cut -f1 > $MYSQLTEST_VARDIR/tmp/bl_dump_thread_id --disable_warnings drop table if exists t999; --enable_warnings create temporary table t999 (f int); --replace_result $MYSQLTEST_VARDIR "." eval LOAD DATA INFILE "$MYSQLTEST_VARDIR/tmp/bl_dump_thread_id" into table t999; let $id = `select f from t999`; drop table t999;
mysql-test/lib/mtr_process.pl +2 −3 Original line number Diff line number Diff line Loading @@ -465,8 +465,7 @@ sub mtr_kill_leftovers () { if ( kill(0, @pids) ) # Check if some left { # FIXME maybe just mtr_warning() ? mtr_error("can't kill process(es) " . join(" ", @pids)); mtr_warning("can't kill process(es) " . join(" ", @pids)); } } } Loading @@ -479,7 +478,7 @@ sub mtr_kill_leftovers () { { if ( mtr_ping_mysqld_server($srv->{'port'}, $srv->{'sockfile'}) ) { mtr_error("can't kill old mysqld holding port $srv->{'port'}"); mtr_warning("can't kill old mysqld holding port $srv->{'port'}"); } } } Loading
mysql-test/mysql-test-run.pl +9 −0 Original line number Diff line number Diff line Loading @@ -312,6 +312,9 @@ our $opt_udiff; our $opt_skip_ndbcluster; our $opt_with_ndbcluster; our $opt_with_ndbcluster_only= 0; # dummy, ignored our $opt_with_openssl; our $exe_ndb_mgm; our $path_ndb_tools_dir; Loading Loading @@ -572,6 +575,7 @@ sub command_line_setup () { 'force' => \$opt_force, 'with-ndbcluster' => \$opt_with_ndbcluster, 'skip-ndbcluster|skip-ndb' => \$opt_skip_ndbcluster, 'with-ndbcluster-only' => \$opt_with_ndbcluster_only, 'do-test=s' => \$opt_do_test, 'suite=s' => \$opt_suite, 'skip-rpl' => \$opt_skip_rpl, Loading Loading @@ -677,6 +681,11 @@ sub command_line_setup () { print '#' x 78, "\n\n"; } if ( $opt_with_ndbcluster_only ) { print "# Option '--with-ndbcluster-only' is ignored in this release.\n"; } foreach my $arg ( @ARGV ) { if ( $arg =~ /^--skip-/ ) Loading
mysql-test/mysql-test-run.sh +12 −0 Original line number Diff line number Diff line Loading @@ -277,6 +277,7 @@ EXTRA_MYSQLSHOW_OPT="" EXTRA_MYSQLBINLOG_OPT="" USE_RUNNING_SERVER=0 USE_NDBCLUSTER=@USE_NDBCLUSTER@ USE_NDBCLUSTER_ONLY=0 USE_RUNNING_NDBCLUSTER="" USE_PURIFY="" PURIFY_LOGS="" Loading Loading @@ -315,6 +316,8 @@ STRESS_INIT_FILE="" STRESS_TEST_FILE="" STRESS_TEST="" $ECHO "Logging: $0 $*" # To ensure we see all arguments in the output, for the test analysis tool while test $# -gt 0; do case "$1" in --embedded-server) Loading @@ -341,6 +344,10 @@ while test $# -gt 0; do --extern) USE_RUNNING_SERVER=1 ;; --with-ndbcluster) USE_NDBCLUSTER="--ndbcluster" ;; --with-ndbcluster-only) USE_NDBCLUSTER="--ndbcluster" USE_NDBCLUSTER_SLAVE="--ndbcluster" USE_NDBCLUSTER_ONLY=1 ;; --ndb-connectstring=*) USE_NDBCLUSTER="--ndbcluster" ; USE_RUNNING_NDBCLUSTER=`$ECHO "$1" | $SED -e "s;--ndb-connectstring=;;"` ;; Loading Loading @@ -1654,6 +1661,11 @@ run_testcase () result_file="r/$tname.result" echo $tname > $CURRENT_TEST SKIP_SLAVE=`$EXPR \( $tname : rpl \) = 0 \& \( $tname : federated \) = 0` NDBCLUSTER_TEST=`$EXPR \( $tname : '.*ndb.*' \) != 0` if [ "x$USE_NDBCLUSTER_ONLY" = "x1" -a "x$NDBCLUSTER_TEST" != "x1" ] ; then skip_test $tname return fi if [ "$USE_MANAGER" = 1 ] ; then many_slaves=`$EXPR \( \( $tname : rpl_failsafe \) != 0 \) \| \( \( $tname : rpl_chain_temp_table \) != 0 \)` fi Loading
mysql-test/r/having.result +35 −0 Original line number Diff line number Diff line Loading @@ -359,3 +359,38 @@ group by s1 collate latin1_swedish_ci having s1 = 'y'; s1 count(s1) y 1 drop table t1; DROP SCHEMA IF EXISTS HU; Warnings: Note 1008 Can't drop database 'HU'; database doesn't exist CREATE SCHEMA HU ; USE HU ; CREATE TABLE STAFF (EMPNUM CHAR(3) NOT NULL UNIQUE, EMPNAME CHAR(20), GRADE DECIMAL(4), CITY CHAR(15)); CREATE TABLE PROJ (PNUM CHAR(3) NOT NULL UNIQUE, PNAME CHAR(20), PTYPE CHAR(6), BUDGET DECIMAL(9), CITY CHAR(15)); INSERT INTO STAFF VALUES ('E1','Alice',12,'Deale'); INSERT INTO STAFF VALUES ('E2','Betty',10,'Vienna'); INSERT INTO STAFF VALUES ('E3','Carmen',13,'Vienna'); INSERT INTO STAFF VALUES ('E4','Don',12,'Deale'); INSERT INTO STAFF VALUES ('E5','Ed',13,'Akron'); INSERT INTO PROJ VALUES ('P1','MXSS','Design',10000,'Deale'); INSERT INTO PROJ VALUES ('P2','CALM','Code',30000,'Vienna'); INSERT INTO PROJ VALUES ('P3','SDP','Test',30000,'Tampa'); INSERT INTO PROJ VALUES ('P4','SDP','Design',20000,'Deale'); INSERT INTO PROJ VALUES ('P5','IRM','Test',10000,'Vienna'); INSERT INTO PROJ VALUES ('P6','PAYR','Design',50000,'Deale'); SELECT EMPNUM, GRADE*1000 FROM HU.STAFF WHERE GRADE * 1000 > ANY (SELECT SUM(BUDGET) FROM HU.PROJ GROUP BY CITY, PTYPE HAVING HU.PROJ.CITY = HU.STAFF.CITY); EMPNUM GRADE*1000 E3 13000 DROP SCHEMA HU;