mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
Merge stella.local:/home2/mydev/mysql-5.1-amain
into stella.local:/home2/mydev/mysql-5.1-axmrg configure.in: Auto merged sql/mysql_priv.h: Auto merged sql/sql_parse.cc: Auto merged sql/sql_plugin.cc: Auto merged sql/sql_table.cc: Auto merged storage/myisam/ha_myisam.cc: Auto merged
This commit is contained in:
@ -108,6 +108,23 @@ drop table t1;
|
||||
set global binlog_cache_size=@bcs;
|
||||
set session autocommit = @ac;
|
||||
|
||||
#
|
||||
# Bug#33798: prepared statements improperly handle large unsigned ints
|
||||
#
|
||||
--disable_warnings
|
||||
drop table if exists t1;
|
||||
--enable_warnings
|
||||
reset master;
|
||||
create table t1 (a bigint unsigned, b bigint(20) unsigned);
|
||||
prepare stmt from "insert into t1 values (?,?)";
|
||||
set @a= 9999999999999999;
|
||||
set @b= 14632475938453979136;
|
||||
execute stmt using @a, @b;
|
||||
deallocate prepare stmt;
|
||||
drop table t1;
|
||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/ /Server ver: [^,]*,/Server version,/
|
||||
show binlog events from 0;
|
||||
|
||||
--echo End of 5.0 tests
|
||||
|
||||
# Test of a too big SET INSERT_ID: see if the truncated value goes
|
||||
|
@ -1743,4 +1743,50 @@ t1 CREATE TABLE `t1` (
|
||||
`MAXLEN` bigint(3) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=utf8
|
||||
drop table t1;
|
||||
|
||||
# --
|
||||
# -- Bug#21380: DEFAULT definition not always transfered by CREATE
|
||||
# -- TABLE/SELECT to the new table.
|
||||
# --
|
||||
|
||||
DROP TABLE IF EXISTS t1;
|
||||
DROP TABLE IF EXISTS t2;
|
||||
|
||||
CREATE TABLE t1(
|
||||
c1 INT DEFAULT 12 COMMENT 'column1',
|
||||
c2 INT NULL COMMENT 'column2',
|
||||
c3 INT NOT NULL COMMENT 'column3',
|
||||
c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a',
|
||||
c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b',
|
||||
c6 VARCHAR(255))
|
||||
COLLATE latin1_bin;
|
||||
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) DEFAULT '12' COMMENT 'column1',
|
||||
`c2` int(11) DEFAULT NULL COMMENT 'column2',
|
||||
`c3` int(11) NOT NULL COMMENT 'column3',
|
||||
`c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a',
|
||||
`c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b',
|
||||
`c6` varchar(255) COLLATE latin1_bin DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin
|
||||
|
||||
CREATE TABLE t2 AS SELECT * FROM t1;
|
||||
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`c1` int(11) DEFAULT '12' COMMENT 'column1',
|
||||
`c2` int(11) DEFAULT NULL COMMENT 'column2',
|
||||
`c3` int(11) NOT NULL COMMENT 'column3',
|
||||
`c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a',
|
||||
`c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b',
|
||||
`c6` varchar(255) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
||||
DROP TABLE t2;
|
||||
|
||||
# -- End of test case for Bug#21380.
|
||||
|
||||
End of 5.1 tests
|
||||
|
@ -722,4 +722,17 @@ DROP USER mysqltest_u1@localhost;
|
||||
#
|
||||
#####################################################################
|
||||
|
||||
drop procedure if exists p;
|
||||
set @old_mode= @@sql_mode;
|
||||
set @@sql_mode= pow(2,32)-1;
|
||||
create event e1 on schedule every 1 day do select 1;
|
||||
select @@sql_mode;
|
||||
@@sql_mode
|
||||
REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,?,ONLY_FULL_GROUP_BY,NO_UNSIGNED_SUBTRACTION,NO_DIR_IN_CREATE,POSTGRESQL,ORACLE,MSSQL,DB2,MAXDB,NO_KEY_OPTIONS,NO_TABLE_OPTIONS,NO_FIELD_OPTIONS,MYSQL323,MYSQL40,ANSI,NO_AUTO_VALUE_ON_ZERO,NO_BACKSLASH_ESCAPES,STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ALLOW_INVALID_DATES,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER,HIGH_NOT_PRECEDENCE,NO_ENGINE_SUBSTITUTION,PAD_CHAR_TO_FULL_LENGTH
|
||||
set @@sql_mode= @old_mode;
|
||||
select replace(@full_mode, '?', 'NOT_USED') into @full_mode;
|
||||
select replace(@full_mode, 'ALLOW_INVALID_DATES', 'INVALID_DATES') into @full_mode;
|
||||
select name from mysql.event where name = 'p' and sql_mode = @full_mode;
|
||||
name
|
||||
drop event e1;
|
||||
DROP DATABASE events_test;
|
||||
|
@ -1218,6 +1218,28 @@ DROP USER mysqltest_1@localhost;
|
||||
DROP DATABASE db27878;
|
||||
use test;
|
||||
DROP TABLE t1;
|
||||
drop table if exists test;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 'test'
|
||||
drop function if exists test_function;
|
||||
Warnings:
|
||||
Note 1305 FUNCTION test_function does not exist
|
||||
drop view if exists v1;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 'test.v1'
|
||||
create table test (col1 varchar(30));
|
||||
create function test_function() returns varchar(30)
|
||||
begin
|
||||
declare tmp varchar(30);
|
||||
select col1 from test limit 1 into tmp;
|
||||
return '1';
|
||||
end|
|
||||
create view v1 as select test.* from test where test.col1=test_function();
|
||||
grant update (col1) on v1 to 'greg'@'localhost';
|
||||
drop user 'greg'@'localhost';
|
||||
drop view v1;
|
||||
drop table test;
|
||||
drop function test_function;
|
||||
End of 5.0 tests
|
||||
set names utf8;
|
||||
grant select on test.* to юзер_юзер@localhost;
|
||||
@ -1282,5 +1304,6 @@ CALL mysqltest1.test();
|
||||
1
|
||||
DROP DATABASE mysqltest1;
|
||||
RENAME TABLE mysql.procs_gone TO mysql.procs_priv;
|
||||
DROP USER mysqltest_1@localhost;
|
||||
FLUSH PRIVILEGES;
|
||||
End of 5.1 tests
|
||||
|
@ -588,7 +588,7 @@ proc body longblob
|
||||
proc definer char(77)
|
||||
proc created timestamp
|
||||
proc modified timestamp
|
||||
proc sql_mode set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE')
|
||||
proc sql_mode set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE','NO_ENGINE_SUBSTITUTION','PAD_CHAR_TO_FULL_LENGTH')
|
||||
proc comment char(64)
|
||||
proc character_set_client char(32)
|
||||
proc collation_connection char(32)
|
||||
@ -1623,4 +1623,19 @@ Db Name Definer Time zone Type Execute at Interval value Interval field Starts E
|
||||
show events where Db= 'information_schema';
|
||||
Db Name Definer Time zone Type Execute at Interval value Interval field Starts Ends Status Originator character_set_client collation_connection Database Collation
|
||||
use test;
|
||||
#
|
||||
# Bug#34166: Server crash in SHOW OPEN TABLES and prelocking
|
||||
#
|
||||
drop table if exists t1;
|
||||
drop function if exists f1;
|
||||
create table t1 (a int);
|
||||
create function f1() returns int
|
||||
begin
|
||||
insert into t1 (a) values (1);
|
||||
return 0;
|
||||
end|
|
||||
show open tables where f1()=0;
|
||||
show open tables where f1()=0;
|
||||
drop table t1;
|
||||
drop function f1;
|
||||
End of 5.1 tests.
|
||||
|
@ -143,4 +143,14 @@ connection: default
|
||||
flush tables;
|
||||
unlock tables;
|
||||
drop table t1;
|
||||
drop table if exists t1,t2;
|
||||
create table t1 (a int);
|
||||
flush status;
|
||||
lock tables t1 read;
|
||||
insert into t1 values(1);;
|
||||
unlock tables;
|
||||
drop table t1;
|
||||
select @tlwa < @tlwb;
|
||||
@tlwa < @tlwb
|
||||
1
|
||||
End of 5.1 tests
|
||||
|
@ -1717,6 +1717,22 @@ t1 CREATE TABLE `t1` (
|
||||
`?` decimal(2,1) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
drop table if exists t1;
|
||||
create table t1 (a bigint unsigned, b bigint(20) unsigned);
|
||||
prepare stmt from "insert into t1 values (?,?)";
|
||||
set @a= 9999999999999999;
|
||||
set @b= 14632475938453979136;
|
||||
insert into t1 values (@a, @b);
|
||||
select * from t1 where a = @a and b = @b;
|
||||
a b
|
||||
9999999999999999 14632475938453979136
|
||||
execute stmt using @a, @b;
|
||||
select * from t1 where a = @a and b = @b;
|
||||
a b
|
||||
9999999999999999 14632475938453979136
|
||||
9999999999999999 14632475938453979136
|
||||
deallocate prepare stmt;
|
||||
drop table t1;
|
||||
End of 5.0 tests.
|
||||
create procedure proc_1() reset query cache;
|
||||
call proc_1();
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1427,4 +1427,9 @@ DROP FUNCTION f1;
|
||||
DROP TABLE t1;
|
||||
DROP EVENT ev1;
|
||||
SHOW TABLE TYPES;
|
||||
CREATE USER test_u@localhost;
|
||||
GRANT PROCESS ON *.* TO test_u@localhost;
|
||||
SHOW ENGINE MYISAM MUTEX;
|
||||
SHOW ENGINE MYISAM STATUS;
|
||||
DROP USER test_u@localhost;
|
||||
End of 5.1 tests
|
||||
|
@ -1627,3 +1627,14 @@ end loop label1;
|
||||
end loop;
|
||||
end|
|
||||
ERROR 42000: End-label label1 without match
|
||||
drop procedure if exists p1;
|
||||
create procedure p1()
|
||||
begin
|
||||
create table t1 (a int) type=MyISAM;
|
||||
drop table t1;
|
||||
end|
|
||||
Warnings:
|
||||
Warning 1287 The syntax 'TYPE=storage_engine' is deprecated and will be removed in MySQL 5.2. Please use 'ENGINE=storage_engine' instead
|
||||
call p1();
|
||||
call p1();
|
||||
drop procedure p1;
|
||||
|
@ -6963,6 +6963,22 @@ END latin1 latin1_swedish_ci latin1_swedish_ci
|
||||
|
||||
DROP FUNCTION f1;
|
||||
|
||||
drop procedure if exists p;
|
||||
set @old_mode= @@sql_mode;
|
||||
set @@sql_mode= pow(2,32)-1;
|
||||
select @@sql_mode into @full_mode;
|
||||
create procedure p() begin end;
|
||||
call p();
|
||||
select @@sql_mode;
|
||||
@@sql_mode
|
||||
REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,?,ONLY_FULL_GROUP_BY,NO_UNSIGNED_SUBTRACTION,NO_DIR_IN_CREATE,POSTGRESQL,ORACLE,MSSQL,DB2,MAXDB,NO_KEY_OPTIONS,NO_TABLE_OPTIONS,NO_FIELD_OPTIONS,MYSQL323,MYSQL40,ANSI,NO_AUTO_VALUE_ON_ZERO,NO_BACKSLASH_ESCAPES,STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ALLOW_INVALID_DATES,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER,HIGH_NOT_PRECEDENCE,NO_ENGINE_SUBSTITUTION,PAD_CHAR_TO_FULL_LENGTH
|
||||
set @@sql_mode= @old_mode;
|
||||
select replace(@full_mode, '?', 'NOT_USED') into @full_mode;
|
||||
select replace(@full_mode, 'ALLOW_INVALID_DATES', 'INVALID_DATES') into @full_mode;
|
||||
select name from mysql.proc where name = 'p' and sql_mode = @full_mode;
|
||||
name
|
||||
p
|
||||
drop procedure p;
|
||||
# ------------------------------------------------------------------
|
||||
# -- End of 5.1 tests
|
||||
# ------------------------------------------------------------------
|
||||
|
@ -201,7 +201,7 @@ proc CREATE TABLE `proc` (
|
||||
`definer` char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL DEFAULT '',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE','NO_ENGINE_SUBSTITUTION','PAD_CHAR_TO_FULL_LENGTH') NOT NULL DEFAULT '',
|
||||
`comment` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`character_set_client` char(32) CHARACTER SET utf8 COLLATE utf8_bin DEFAULT NULL,
|
||||
`collation_connection` char(32) CHARACTER SET utf8 COLLATE utf8_bin DEFAULT NULL,
|
||||
@ -226,7 +226,7 @@ event CREATE TABLE `event` (
|
||||
`ends` datetime DEFAULT NULL,
|
||||
`status` enum('ENABLED','DISABLED','SLAVESIDE_DISABLED') NOT NULL DEFAULT 'ENABLED',
|
||||
`on_completion` enum('DROP','PRESERVE') NOT NULL DEFAULT 'DROP',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL DEFAULT '',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE','NO_ENGINE_SUBSTITUTION','PAD_CHAR_TO_FULL_LENGTH') NOT NULL DEFAULT '',
|
||||
`comment` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`originator` int(10) NOT NULL,
|
||||
`time_zone` char(64) CHARACTER SET latin1 NOT NULL DEFAULT 'SYSTEM',
|
||||
|
@ -1072,6 +1072,22 @@ master-bin.000001 30301 Rotate 1 30345 master-bin.000002;pos=4
|
||||
drop table t1;
|
||||
set global binlog_cache_size=@bcs;
|
||||
set session autocommit = @ac;
|
||||
drop table if exists t1;
|
||||
reset master;
|
||||
create table t1 (a bigint unsigned, b bigint(20) unsigned);
|
||||
prepare stmt from "insert into t1 values (?,?)";
|
||||
set @a= 9999999999999999;
|
||||
set @b= 14632475938453979136;
|
||||
execute stmt using @a, @b;
|
||||
deallocate prepare stmt;
|
||||
drop table t1;
|
||||
show binlog events from 0;
|
||||
Log_name Pos Event_type Server_id End_log_pos Info
|
||||
master-bin.000001 4 Format_desc 1 106 Server version, Binlog ver: 4
|
||||
master-bin.000001 106 Query 1 227 use `test`; create table t1 (a bigint unsigned, b bigint(20) unsigned)
|
||||
master-bin.000001 227 Table_map 1 269 table_id: # (test.t1)
|
||||
master-bin.000001 269 Write_rows 1 315 table_id: # flags: STMT_END_F
|
||||
master-bin.000001 315 Query 1 391 use `test`; drop table t1
|
||||
End of 5.0 tests
|
||||
reset master;
|
||||
create table t1 (id tinyint auto_increment primary key);
|
||||
|
@ -579,6 +579,21 @@ master-bin.000001 36593 Rotate 1 36637 master-bin.000002;pos=4
|
||||
drop table t1;
|
||||
set global binlog_cache_size=@bcs;
|
||||
set session autocommit = @ac;
|
||||
drop table if exists t1;
|
||||
reset master;
|
||||
create table t1 (a bigint unsigned, b bigint(20) unsigned);
|
||||
prepare stmt from "insert into t1 values (?,?)";
|
||||
set @a= 9999999999999999;
|
||||
set @b= 14632475938453979136;
|
||||
execute stmt using @a, @b;
|
||||
deallocate prepare stmt;
|
||||
drop table t1;
|
||||
show binlog events from 0;
|
||||
Log_name Pos Event_type Server_id End_log_pos Info
|
||||
master-bin.000001 4 Format_desc 1 106 Server version, Binlog ver: 4
|
||||
master-bin.000001 106 Query 1 227 use `test`; create table t1 (a bigint unsigned, b bigint(20) unsigned)
|
||||
master-bin.000001 227 Query 1 351 use `test`; insert into t1 values (9999999999999999,14632475938453979136)
|
||||
master-bin.000001 351 Query 1 427 use `test`; drop table t1
|
||||
End of 5.0 tests
|
||||
reset master;
|
||||
create table t1 (id tinyint auto_increment primary key);
|
||||
|
@ -20,3 +20,8 @@ rpl_ndb_mix_innodb : Bug #32720 Test rpl_ndb_mix_innodb fails on SPARC a
|
||||
# the below testcase have been reworked to avoid the bug, test contains comment, keep bug open
|
||||
|
||||
#rpl_ndb_dd_advance : Bug#25913 rpl_ndb_dd_advance fails randomly
|
||||
|
||||
|
||||
rpl_ndb_innodb_trans : Bug#34454: Some test cases from the 'rpl_ndb' suite fail
|
||||
rpl_ndb_charset : Bug#34454: Some test cases from the 'rpl_ndb' suite fail
|
||||
rpl_ndb_multi : Bug#34454: Some test cases from the 'rpl_ndb' suite fail
|
||||
|
@ -1341,4 +1341,48 @@ create table t1 like information_schema.character_sets;
|
||||
show create table t1;
|
||||
drop table t1;
|
||||
|
||||
--echo
|
||||
--echo # --
|
||||
--echo # -- Bug#21380: DEFAULT definition not always transfered by CREATE
|
||||
--echo # -- TABLE/SELECT to the new table.
|
||||
--echo # --
|
||||
--echo
|
||||
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t1;
|
||||
DROP TABLE IF EXISTS t2;
|
||||
--enable_warnings
|
||||
|
||||
--echo
|
||||
|
||||
CREATE TABLE t1(
|
||||
c1 INT DEFAULT 12 COMMENT 'column1',
|
||||
c2 INT NULL COMMENT 'column2',
|
||||
c3 INT NOT NULL COMMENT 'column3',
|
||||
c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a',
|
||||
c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b',
|
||||
c6 VARCHAR(255))
|
||||
COLLATE latin1_bin;
|
||||
|
||||
--echo
|
||||
|
||||
SHOW CREATE TABLE t1;
|
||||
|
||||
--echo
|
||||
|
||||
CREATE TABLE t2 AS SELECT * FROM t1;
|
||||
|
||||
--echo
|
||||
|
||||
SHOW CREATE TABLE t2;
|
||||
|
||||
--echo
|
||||
|
||||
DROP TABLE t2;
|
||||
|
||||
--echo
|
||||
--echo # -- End of test case for Bug#21380.
|
||||
--echo
|
||||
|
||||
--echo End of 5.1 tests
|
||||
|
@ -23,3 +23,4 @@ wait_timeout : Bug#32801 wait_timeout.test fails randomly
|
||||
ctype_create : Bug#32965 main.ctype_create fails
|
||||
status : Bug#32966 main.status fails
|
||||
ps_ddl : Bug#12093 2007-12-14 pending WL#4165 / WL#4166
|
||||
query_cache_debug : Bug#34424: query_cache_debug.test leads to valgrind warnings
|
||||
|
@ -935,6 +935,26 @@ DROP USER mysqltest_u1@localhost;
|
||||
--echo #####################################################################
|
||||
--echo
|
||||
|
||||
#
|
||||
# Bug#32633 Can not create any routine if SQL_MODE=no_engine_substitution
|
||||
#
|
||||
# Ensure that when new SQL modes are introduced, they are also added to
|
||||
# the mysql.event table.
|
||||
#
|
||||
|
||||
--disable_warnings
|
||||
drop procedure if exists p;
|
||||
--enable_warnings
|
||||
set @old_mode= @@sql_mode;
|
||||
set @@sql_mode= pow(2,32)-1;
|
||||
create event e1 on schedule every 1 day do select 1;
|
||||
select @@sql_mode;
|
||||
set @@sql_mode= @old_mode;
|
||||
# Rename SQL modes that differ in name between the server and the table definition.
|
||||
select replace(@full_mode, '?', 'NOT_USED') into @full_mode;
|
||||
select replace(@full_mode, 'ALLOW_INVALID_DATES', 'INVALID_DATES') into @full_mode;
|
||||
select name from mysql.event where name = 'p' and sql_mode = @full_mode;
|
||||
drop event e1;
|
||||
|
||||
###########################################################################
|
||||
#
|
||||
|
@ -1266,6 +1266,28 @@ DROP DATABASE db27878;
|
||||
use test;
|
||||
DROP TABLE t1;
|
||||
|
||||
#
|
||||
# Bug #33201 Crash occurs when granting update privilege on one column of a view
|
||||
#
|
||||
drop table if exists test;
|
||||
drop function if exists test_function;
|
||||
drop view if exists v1;
|
||||
create table test (col1 varchar(30));
|
||||
delimiter |;
|
||||
create function test_function() returns varchar(30)
|
||||
begin
|
||||
declare tmp varchar(30);
|
||||
select col1 from test limit 1 into tmp;
|
||||
return '1';
|
||||
end|
|
||||
delimiter ;|
|
||||
create view v1 as select test.* from test where test.col1=test_function();
|
||||
grant update (col1) on v1 to 'greg'@'localhost';
|
||||
drop user 'greg'@'localhost';
|
||||
drop view v1;
|
||||
drop table test;
|
||||
drop function test_function;
|
||||
|
||||
--echo End of 5.0 tests
|
||||
|
||||
#
|
||||
@ -1374,6 +1396,7 @@ GRANT ALL PRIVILEGES ON test.* TO mysqltest_1@localhost;
|
||||
CALL mysqltest1.test();
|
||||
DROP DATABASE mysqltest1;
|
||||
RENAME TABLE mysql.procs_gone TO mysql.procs_priv;
|
||||
DROP USER mysqltest_1@localhost;
|
||||
FLUSH PRIVILEGES;
|
||||
|
||||
|
||||
|
@ -1248,4 +1248,26 @@ show events from information_schema;
|
||||
show events where Db= 'information_schema';
|
||||
use test;
|
||||
|
||||
--echo #
|
||||
--echo # Bug#34166: Server crash in SHOW OPEN TABLES and prelocking
|
||||
--echo #
|
||||
--disable_warnings
|
||||
drop table if exists t1;
|
||||
drop function if exists f1;
|
||||
--enable_warnings
|
||||
create table t1 (a int);
|
||||
delimiter |;
|
||||
create function f1() returns int
|
||||
begin
|
||||
insert into t1 (a) values (1);
|
||||
return 0;
|
||||
end|
|
||||
delimiter ;|
|
||||
--disable_result_log
|
||||
show open tables where f1()=0;
|
||||
show open tables where f1()=0;
|
||||
--enable_result_log
|
||||
drop table t1;
|
||||
drop function f1;
|
||||
|
||||
--echo End of 5.1 tests.
|
||||
|
@ -439,4 +439,34 @@ connection default;
|
||||
disconnect flush;
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# Bug#30331: Table_locks_waited shows inaccurate values
|
||||
#
|
||||
|
||||
--disable_warnings
|
||||
drop table if exists t1,t2;
|
||||
--enable_warnings
|
||||
create table t1 (a int);
|
||||
flush status;
|
||||
lock tables t1 read;
|
||||
let $tlwa= `show status like 'Table_locks_waited'`;
|
||||
connect (waiter,localhost,root,,);
|
||||
connection waiter;
|
||||
--send insert into t1 values(1);
|
||||
connection default;
|
||||
let $wait_condition=
|
||||
select count(*) = 1 from information_schema.processlist
|
||||
where state = "Locked" and info = "insert into t1 values(1)";
|
||||
--source include/wait_condition.inc
|
||||
let $tlwb= `show status like 'Table_locks_waited'`;
|
||||
unlock tables;
|
||||
drop table t1;
|
||||
disconnect waiter;
|
||||
connection default;
|
||||
--disable_query_log
|
||||
eval SET @tlwa= SUBSTRING_INDEX('$tlwa', ' ', -1);
|
||||
eval SET @tlwb= SUBSTRING_INDEX('$tlwb', ' ', -1);
|
||||
--enable_query_log
|
||||
select @tlwa < @tlwb;
|
||||
|
||||
--echo End of 5.1 tests
|
||||
|
@ -2101,5 +2101,28 @@ drop table t1;
|
||||
--change_user root,,
|
||||
--change_user root,,test
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
# Test mkdir and rmdir command
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
mkdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
rmdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
|
||||
# Directory already exist
|
||||
mkdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
--error 1
|
||||
mkdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
|
||||
# Remove dir with file inside
|
||||
write_file $MYSQLTEST_VARDIR/tmp/testdir/file1.txt;
|
||||
hello
|
||||
EOF
|
||||
--error 1
|
||||
rmdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
|
||||
remove_file $MYSQLTEST_VARDIR/tmp/testdir/file1.txt;
|
||||
rmdir $MYSQLTEST_VARDIR/tmp/testdir;
|
||||
|
||||
|
||||
--echo End of tests
|
||||
|
||||
|
@ -1821,6 +1821,23 @@ execute stmt using @a;
|
||||
show create table t1;
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# Bug#33798: prepared statements improperly handle large unsigned ints
|
||||
#
|
||||
--disable_warnings
|
||||
drop table if exists t1;
|
||||
--enable_warnings
|
||||
create table t1 (a bigint unsigned, b bigint(20) unsigned);
|
||||
prepare stmt from "insert into t1 values (?,?)";
|
||||
set @a= 9999999999999999;
|
||||
set @b= 14632475938453979136;
|
||||
insert into t1 values (@a, @b);
|
||||
select * from t1 where a = @a and b = @b;
|
||||
execute stmt using @a, @b;
|
||||
select * from t1 where a = @a and b = @b;
|
||||
deallocate prepare stmt;
|
||||
drop table t1;
|
||||
|
||||
--echo End of 5.0 tests.
|
||||
|
||||
#
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1115,5 +1115,24 @@ DROP EVENT ev1;
|
||||
SHOW TABLE TYPES;
|
||||
--enable_result_log
|
||||
|
||||
#
|
||||
# Bug #32710: SHOW INNODB STATUS requires SUPER
|
||||
#
|
||||
|
||||
|
||||
CREATE USER test_u@localhost;
|
||||
GRANT PROCESS ON *.* TO test_u@localhost;
|
||||
|
||||
connect (conn1, localhost, test_u,,);
|
||||
|
||||
--disable_result_log
|
||||
SHOW ENGINE MYISAM MUTEX;
|
||||
SHOW ENGINE MYISAM STATUS;
|
||||
--enable_result_log
|
||||
|
||||
disconnect conn1;
|
||||
connection default;
|
||||
DROP USER test_u@localhost;
|
||||
|
||||
|
||||
--echo End of 5.1 tests
|
||||
|
@ -2368,6 +2368,24 @@ end|
|
||||
|
||||
delimiter ;|
|
||||
|
||||
#
|
||||
# Bug#21801: SQL exception handlers and warnings
|
||||
#
|
||||
|
||||
--disable_warnings
|
||||
drop procedure if exists p1;
|
||||
--enable_warnings
|
||||
delimiter |;
|
||||
create procedure p1()
|
||||
begin
|
||||
create table t1 (a int) type=MyISAM;
|
||||
drop table t1;
|
||||
end|
|
||||
delimiter ;|
|
||||
call p1();
|
||||
call p1();
|
||||
drop procedure p1;
|
||||
|
||||
#
|
||||
# BUG#NNNN: New bug synopsis
|
||||
#
|
||||
|
@ -8135,6 +8135,29 @@ DROP FUNCTION f1;
|
||||
|
||||
###########################################################################
|
||||
|
||||
#
|
||||
# Bug#32633 Can not create any routine if SQL_MODE=no_engine_substitution
|
||||
#
|
||||
# Ensure that when new SQL modes are introduced, they are also added to
|
||||
# the mysql.proc table.
|
||||
#
|
||||
|
||||
--disable_warnings
|
||||
drop procedure if exists p;
|
||||
--enable_warnings
|
||||
set @old_mode= @@sql_mode;
|
||||
set @@sql_mode= pow(2,32)-1;
|
||||
select @@sql_mode into @full_mode;
|
||||
create procedure p() begin end;
|
||||
call p();
|
||||
select @@sql_mode;
|
||||
set @@sql_mode= @old_mode;
|
||||
# Rename SQL modes that differ in name between the server and the table definition.
|
||||
select replace(@full_mode, '?', 'NOT_USED') into @full_mode;
|
||||
select replace(@full_mode, 'ALLOW_INVALID_DATES', 'INVALID_DATES') into @full_mode;
|
||||
select name from mysql.proc where name = 'p' and sql_mode = @full_mode;
|
||||
drop procedure p;
|
||||
|
||||
--echo # ------------------------------------------------------------------
|
||||
--echo # -- End of 5.1 tests
|
||||
--echo # ------------------------------------------------------------------
|
||||
|
@ -78,7 +78,7 @@ CREATE TABLE IF NOT EXISTS proc ( db char(64) collate utf8_bin DEFAULT '' NOT NU
|
||||
|
||||
CREATE TABLE IF NOT EXISTS procs_priv ( Host char(60) binary DEFAULT '' NOT NULL, Db char(64) binary DEFAULT '' NOT NULL, User char(16) binary DEFAULT '' NOT NULL, Routine_name char(64) binary DEFAULT '' NOT NULL, Routine_type enum('FUNCTION','PROCEDURE') NOT NULL, Grantor char(77) DEFAULT '' NOT NULL, Proc_priv set('Execute','Alter Routine','Grant') COLLATE utf8_general_ci DEFAULT '' NOT NULL, Timestamp timestamp(14), PRIMARY KEY (Host,Db,User,Routine_name,Routine_type), KEY Grantor (Grantor) ) engine=MyISAM CHARACTER SET utf8 COLLATE utf8_bin comment='Procedure privileges';
|
||||
|
||||
CREATE TABLE IF NOT EXISTS event ( db char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', name char(64) CHARACTER SET utf8 NOT NULL default '', body longblob NOT NULL, definer char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', execute_at DATETIME default NULL, interval_value int(11) default NULL, interval_field ENUM('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') default NULL, created TIMESTAMP NOT NULL, modified TIMESTAMP NOT NULL, last_executed DATETIME default NULL, starts DATETIME default NULL, ends DATETIME default NULL, status ENUM('ENABLED','DISABLED') NOT NULL default 'ENABLED', on_completion ENUM('DROP','PRESERVE') NOT NULL default 'DROP', sql_mode set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') DEFAULT '' NOT NULL, comment char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', time_zone char(64) CHARACTER SET latin1 NOT NULL DEFAULT 'SYSTEM', PRIMARY KEY (db, name) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT 'Events';
|
||||
CREATE TABLE IF NOT EXISTS event ( db char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', name char(64) CHARACTER SET utf8 NOT NULL default '', body longblob NOT NULL, definer char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', execute_at DATETIME default NULL, interval_value int(11) default NULL, interval_field ENUM('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') default NULL, created TIMESTAMP NOT NULL, modified TIMESTAMP NOT NULL, last_executed DATETIME default NULL, starts DATETIME default NULL, ends DATETIME default NULL, status ENUM('ENABLED','DISABLED') NOT NULL default 'ENABLED', on_completion ENUM('DROP','PRESERVE') NOT NULL default 'DROP', sql_mode set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE','NO_ENGINE_SUBSTITUTION','PAD_CHAR_TO_FULL_LENGTH') DEFAULT '' NOT NULL, comment char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL default '', time_zone char(64) CHARACTER SET latin1 NOT NULL DEFAULT 'SYSTEM', PRIMARY KEY (db, name) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT 'Events';
|
||||
|
||||
CREATE TABLE IF NOT EXISTS ndb_binlog_index (Position BIGINT UNSIGNED NOT NULL, File VARCHAR(255) NOT NULL, epoch BIGINT UNSIGNED NOT NULL, inserts BIGINT UNSIGNED NOT NULL, updates BIGINT UNSIGNED NOT NULL, deletes BIGINT UNSIGNED NOT NULL, schemaops BIGINT UNSIGNED NOT NULL, PRIMARY KEY(epoch)) ENGINE=MYISAM;
|
||||
|
||||
|
@ -1,10 +1,5 @@
|
||||
-- source include/not_embedded.inc
|
||||
|
||||
# Temporary disabled on windows,
|
||||
# because of --exec mkdir
|
||||
# TODO: implement Bug#31004 and remove this limitation
|
||||
--source include/not_windows.inc
|
||||
|
||||
--disable_warnings
|
||||
drop database if exists `mysqltest1`;
|
||||
drop database if exists `mysqltest-1`;
|
||||
@ -75,7 +70,7 @@ create table tabc.t1 (a int);
|
||||
FLUSH TABLES;
|
||||
|
||||
# Manually make a 5.0 database from the template
|
||||
--exec mkdir $MYSQLTEST_VARDIR/master-data/a-b-c
|
||||
--mkdir $MYSQLTEST_VARDIR/master-data/a-b-c
|
||||
--copy_file $MYSQLTEST_VARDIR/master-data/tabc/db.opt $MYSQLTEST_VARDIR/master-data/a-b-c/db.opt
|
||||
--copy_file $MYSQLTEST_VARDIR/master-data/tabc/t1.frm $MYSQLTEST_VARDIR/master-data/a-b-c/t1.frm
|
||||
--copy_file $MYSQLTEST_VARDIR/master-data/tabc/t1.MYD $MYSQLTEST_VARDIR/master-data/a-b-c/t1.MYD
|
||||
|
Reference in New Issue
Block a user