mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
Merge alik.:/mnt/raid/alik/MySQL/devel/5.0-rt
into alik.:/mnt/raid/alik/MySQL/devel/5.0-merged-5.0-rt configure.in: Auto merged include/my_time.h: Auto merged mysql-test/r/func_time.result: Auto merged mysql-test/r/rename.result: Auto merged mysql-test/t/func_time.test: Auto merged mysql-test/t/im_daemon_life_cycle.imtest: Auto merged mysql-test/t/rename.test: Auto merged sql-common/my_time.c: Auto merged sql/item_timefunc.cc: Auto merged sql/time.cc: Auto merged
This commit is contained in:
commit
b4093b65be
185 changed files with 13445 additions and 5742 deletions
|
|
@ -1,6 +1,6 @@
|
|||
drop table if exists t1;
|
||||
create table t1(n int not null, key(n), key(n), key(n), key(n));
|
||||
check table t1 extended;
|
||||
check table t1 extended;
|
||||
insert into t1 values (200000);
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 check status OK
|
||||
|
|
|
|||
|
|
@ -767,11 +767,5 @@ t1 CREATE TABLE `t1` (
|
|||
`i` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=4294967295
|
||||
drop table t1;
|
||||
create table t1(f1 varchar(800) binary not null, key(f1)) engine = innodb
|
||||
character set utf8 collate utf8_general_ci;
|
||||
Warnings:
|
||||
Warning 1071 Specified key was too long; max key length is 765 bytes
|
||||
insert into t1 values('aaa');
|
||||
drop table t1;
|
||||
create table t1 (upgrade int);
|
||||
drop table t1;
|
||||
|
|
|
|||
|
|
@ -4913,8 +4913,7 @@ bonfire
|
|||
Colombo
|
||||
nondecreasing
|
||||
DROP TABLE t1;
|
||||
ALTER TABLE t2 RENAME t1
|
||||
#;
|
||||
ALTER TABLE t2 RENAME t1;
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (
|
||||
Period smallint(4) unsigned zerofill DEFAULT '0000' NOT NULL,
|
||||
|
|
|
|||
|
|
@ -77,9 +77,9 @@ drop table if exists t1;
|
|||
create table t1 (i int);
|
||||
lock tables t1 read;
|
||||
create database mysqltest;
|
||||
drop table t1;
|
||||
drop table t1;
|
||||
show open tables;
|
||||
drop database mysqltest;
|
||||
drop database mysqltest;
|
||||
select 1;
|
||||
1
|
||||
1
|
||||
|
|
|
|||
|
|
@ -9,13 +9,13 @@ n
|
|||
flush tables with read lock;
|
||||
drop table t2;
|
||||
ERROR HY000: Can't execute the query because you have a conflicting read lock
|
||||
drop table t2;
|
||||
drop table t2;
|
||||
unlock tables;
|
||||
create database mysqltest;
|
||||
create table mysqltest.t1(n int);
|
||||
insert into mysqltest.t1 values (23);
|
||||
flush tables with read lock;
|
||||
drop database mysqltest;
|
||||
drop database mysqltest;
|
||||
select * from mysqltest.t1;
|
||||
n
|
||||
23
|
||||
|
|
@ -51,7 +51,7 @@ drop table t1, t2, t3;
|
|||
create table t1 (c1 int);
|
||||
create table t2 (c1 int);
|
||||
lock table t1 write;
|
||||
flush tables with read lock;
|
||||
insert into t2 values(1);
|
||||
flush tables with read lock;
|
||||
insert into t2 values(1);
|
||||
unlock tables;
|
||||
drop table t1, t2;
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ insert into t1 values(1);
|
|||
flush tables with read lock;
|
||||
select * from t1;
|
||||
a
|
||||
commit;
|
||||
commit;
|
||||
select * from t1;
|
||||
a
|
||||
unlock tables;
|
||||
|
|
@ -14,8 +14,8 @@ select * from t1 for update;
|
|||
a
|
||||
1
|
||||
begin;
|
||||
select * from t1 for update;
|
||||
flush tables with read lock;
|
||||
select * from t1 for update;
|
||||
flush tables with read lock;
|
||||
commit;
|
||||
a
|
||||
1
|
||||
|
|
@ -45,7 +45,7 @@ flush tables with read lock;
|
|||
show master status;
|
||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||
master-bin.000001 98
|
||||
commit;
|
||||
commit;
|
||||
show master status;
|
||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||
master-bin.000001 98
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
drop table if exists t1;
|
||||
create table t1 (kill_id int);
|
||||
insert into t1 values(connection_id());
|
||||
flush tables with read lock;
|
||||
flush tables with read lock;
|
||||
select ((@id := kill_id) - kill_id) from t1;
|
||||
((@id := kill_id) - kill_id)
|
||||
0
|
||||
|
|
|
|||
|
|
@ -79,6 +79,16 @@ uncompress(a) uncompressed_length(a)
|
|||
NULL NULL
|
||||
a 1
|
||||
drop table t1;
|
||||
create table t1(a blob);
|
||||
insert into t1 values ('0'), (NULL), ('0');
|
||||
select compress(a), compress(a) from t1;
|
||||
select compress(a) is null from t1;
|
||||
compress(a) is null
|
||||
0
|
||||
1
|
||||
0
|
||||
drop table t1;
|
||||
End of 4.1 tests
|
||||
create table t1 (a varchar(32) not null);
|
||||
insert into t1 values ('foo');
|
||||
explain select * from t1 where uncompress(a) is null;
|
||||
|
|
|
|||
|
|
@ -71,3 +71,17 @@ NULL
|
|||
NULL
|
||||
NULL
|
||||
drop table t1;
|
||||
End of 4.1 tests
|
||||
SELECT CAST('2006-09-26' AS DATE) + INTERVAL 1 DAY;
|
||||
CAST('2006-09-26' AS DATE) + INTERVAL 1 DAY
|
||||
2006-09-27
|
||||
SELECT CAST('2006-09-26' AS DATE) + INTERVAL 1 MONTH;
|
||||
CAST('2006-09-26' AS DATE) + INTERVAL 1 MONTH
|
||||
2006-10-26
|
||||
SELECT CAST('2006-09-26' AS DATE) + INTERVAL 1 YEAR;
|
||||
CAST('2006-09-26' AS DATE) + INTERVAL 1 YEAR
|
||||
2007-09-26
|
||||
SELECT CAST('2006-09-26' AS DATE) + INTERVAL 1 WEEK;
|
||||
CAST('2006-09-26' AS DATE) + INTERVAL 1 WEEK
|
||||
2006-10-03
|
||||
End of 5.0 tests
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ FROM t1
|
|||
WHERE conn = 'default';
|
||||
IS_USED_LOCK('bug16501') = connection_id
|
||||
1
|
||||
SELECT GET_LOCK('bug16501',600);
|
||||
SELECT GET_LOCK('bug16501',600);
|
||||
SELECT IS_USED_LOCK('bug16501') = CONNECTION_ID();
|
||||
IS_USED_LOCK('bug16501') = CONNECTION_ID()
|
||||
1
|
||||
|
|
|
|||
|
|
@ -107,7 +107,9 @@ subtime("02:01:01.999999", "01:01:01.999999")
|
|||
01:00:00.000000
|
||||
select timediff("1997-01-01 23:59:59.000001","1995-12-31 23:59:59.000002");
|
||||
timediff("1997-01-01 23:59:59.000001","1995-12-31 23:59:59.000002")
|
||||
8807:59:59.999999
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '8807:59:59.999999'
|
||||
select timediff("1997-12-31 23:59:59.000001","1997-12-30 01:01:01.000002");
|
||||
timediff("1997-12-31 23:59:59.000001","1997-12-30 01:01:01.000002")
|
||||
46:58:57.999999
|
||||
|
|
@ -219,13 +221,16 @@ SELECT TIMEDIFF(t1, t4) As ttt, TIMEDIFF(t2, t3) As qqq,
|
|||
TIMEDIFF(t3, t2) As eee, TIMEDIFF(t2, t4) As rrr from test;
|
||||
ttt qqq eee rrr
|
||||
-744:00:00 NULL NULL NULL
|
||||
26305:01:02 22:58:58 -22:58:58 NULL
|
||||
-26305:01:02 -22:58:58 22:58:58 NULL
|
||||
838:59:59 22:58:58 -22:58:58 NULL
|
||||
-838:59:59 -22:58:58 22:58:58 NULL
|
||||
NULL 26:02:02 -26:02:02 NULL
|
||||
00:00:00 -26:02:02 26:02:02 NULL
|
||||
NULL NULL NULL NULL
|
||||
NULL NULL NULL NULL
|
||||
00:00:00 -24:00:00 24:00:00 NULL
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '26305:01:02'
|
||||
Warning 1292 Truncated incorrect time value: '-26305:01:02'
|
||||
drop table t1, test;
|
||||
select addtime("-01:01:01.01", "-23:59:59.1") as a;
|
||||
a
|
||||
|
|
@ -235,7 +240,9 @@ a
|
|||
10000
|
||||
select microsecond(19971231235959.01) as a;
|
||||
a
|
||||
10000
|
||||
0
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '19971231235959.01'
|
||||
select date_add("1997-12-31",INTERVAL "10.09" SECOND_MICROSECOND) as a;
|
||||
a
|
||||
1997-12-31 00:00:10.090000
|
||||
|
|
|
|||
|
|
@ -339,7 +339,9 @@ extract(DAY_MINUTE FROM "02 10:11:12")
|
|||
21011
|
||||
select extract(DAY_SECOND FROM "225 10:11:12");
|
||||
extract(DAY_SECOND FROM "225 10:11:12")
|
||||
225101112
|
||||
8385959
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '225 10:11:12'
|
||||
select extract(HOUR FROM "1999-01-02 10:11:12");
|
||||
extract(HOUR FROM "1999-01-02 10:11:12")
|
||||
10
|
||||
|
|
@ -648,7 +650,7 @@ date_add(date,INTERVAL "1 1:1:1" DAY_SECOND)
|
|||
2003-01-03 01:01:01
|
||||
select date_add(date,INTERVAL "1" WEEK) from t1;
|
||||
date_add(date,INTERVAL "1" WEEK)
|
||||
2003-01-09 00:00:00
|
||||
2003-01-09
|
||||
select date_add(date,INTERVAL "1" QUARTER) from t1;
|
||||
date_add(date,INTERVAL "1" QUARTER)
|
||||
2003-04-02
|
||||
|
|
@ -657,7 +659,7 @@ timestampadd(MINUTE, 1, date)
|
|||
2003-01-02 00:01:00
|
||||
select timestampadd(WEEK, 1, date) from t1;
|
||||
timestampadd(WEEK, 1, date)
|
||||
2003-01-09 00:00:00
|
||||
2003-01-09
|
||||
select timestampadd(SQL_TSI_SECOND, 1, date) from t1;
|
||||
timestampadd(SQL_TSI_SECOND, 1, date)
|
||||
2003-01-02 00:00:01
|
||||
|
|
@ -926,6 +928,93 @@ t1 CREATE TABLE `t1` (
|
|||
`from_unixtime(1) + 0` double(23,6) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
SELECT SEC_TO_TIME(3300000);
|
||||
SEC_TO_TIME(3300000)
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '3300000'
|
||||
SELECT SEC_TO_TIME(3300000)+0;
|
||||
SEC_TO_TIME(3300000)+0
|
||||
8385959.000000
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '3300000'
|
||||
SELECT SEC_TO_TIME(3600 * 4294967296);
|
||||
SEC_TO_TIME(3600 * 4294967296)
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '15461882265600'
|
||||
SELECT TIME_TO_SEC('916:40:00');
|
||||
TIME_TO_SEC('916:40:00')
|
||||
3020399
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '916:40:00'
|
||||
SELECT ADDTIME('500:00:00', '416:40:00');
|
||||
ADDTIME('500:00:00', '416:40:00')
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '916:40:00'
|
||||
SELECT ADDTIME('916:40:00', '416:40:00');
|
||||
ADDTIME('916:40:00', '416:40:00')
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '916:40:00'
|
||||
Warning 1292 Truncated incorrect time value: '1255:39:59'
|
||||
SELECT SUBTIME('916:40:00', '416:40:00');
|
||||
SUBTIME('916:40:00', '416:40:00')
|
||||
422:19:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '916:40:00'
|
||||
SELECT SUBTIME('-916:40:00', '416:40:00');
|
||||
SUBTIME('-916:40:00', '416:40:00')
|
||||
-838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '-916:40:00'
|
||||
Warning 1292 Truncated incorrect time value: '-1255:39:59'
|
||||
SELECT MAKETIME(916,0,0);
|
||||
MAKETIME(916,0,0)
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '916:00:00'
|
||||
SELECT MAKETIME(4294967296, 0, 0);
|
||||
MAKETIME(4294967296, 0, 0)
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '4294967296:00:00'
|
||||
SELECT MAKETIME(-4294967296, 0, 0);
|
||||
MAKETIME(-4294967296, 0, 0)
|
||||
-838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '-4294967296:00:00'
|
||||
SELECT MAKETIME(0, 4294967296, 0);
|
||||
MAKETIME(0, 4294967296, 0)
|
||||
NULL
|
||||
SELECT MAKETIME(0, 0, 4294967296);
|
||||
MAKETIME(0, 0, 4294967296)
|
||||
NULL
|
||||
SELECT MAKETIME(CAST(-1 AS UNSIGNED), 0, 0);
|
||||
MAKETIME(CAST(-1 AS UNSIGNED), 0, 0)
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '18446744073709551615:00:00'
|
||||
SELECT EXTRACT(HOUR FROM '100000:02:03');
|
||||
EXTRACT(HOUR FROM '100000:02:03')
|
||||
838
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '100000:02:03'
|
||||
CREATE TABLE t1(f1 TIME);
|
||||
INSERT INTO t1 VALUES('916:00:00 a');
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'f1' at row 1
|
||||
Warning 1264 Out of range value adjusted for column 'f1' at row 1
|
||||
SELECT * FROM t1;
|
||||
f1
|
||||
838:59:59
|
||||
DROP TABLE t1;
|
||||
SELECT SEC_TO_TIME(CAST(-1 AS UNSIGNED));
|
||||
SEC_TO_TIME(CAST(-1 AS UNSIGNED))
|
||||
838:59:59
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect time value: '18446744073709551615'
|
||||
SET NAMES latin1;
|
||||
SET character_set_results = NULL;
|
||||
SHOW VARIABLES LIKE 'character_set_results';
|
||||
|
|
|
|||
|
|
@ -336,12 +336,12 @@ drop database mysqltest_1;
|
|||
set password = password("changed");
|
||||
ERROR 42000: Access denied for user ''@'localhost' to database 'mysql'
|
||||
lock table mysql.user write;
|
||||
flush privileges;
|
||||
grant all on *.* to 'mysqltest_1'@'localhost';
|
||||
flush privileges;
|
||||
grant all on *.* to 'mysqltest_1'@'localhost';
|
||||
unlock tables;
|
||||
lock table mysql.user write;
|
||||
set password for 'mysqltest_1'@'localhost' = password('');
|
||||
revoke all on *.* from 'mysqltest_1'@'localhost';
|
||||
set password for 'mysqltest_1'@'localhost' = password('');
|
||||
revoke all on *.* from 'mysqltest_1'@'localhost';
|
||||
unlock tables;
|
||||
drop user 'mysqltest_1'@'localhost';
|
||||
create database TESTDB;
|
||||
|
|
|
|||
|
|
@ -452,7 +452,7 @@ handler t1 read first;
|
|||
c1
|
||||
1
|
||||
send the below to another connection, do not wait for the result
|
||||
optimize table t1;
|
||||
optimize table t1;
|
||||
proceed with the normal connection
|
||||
handler t1 read next;
|
||||
c1
|
||||
|
|
@ -469,7 +469,7 @@ flush tables with read lock;
|
|||
drop table t1;
|
||||
ERROR HY000: Can't execute the query because you have a conflicting read lock
|
||||
send the below to another connection, do not wait for the result
|
||||
drop table t1;
|
||||
drop table t1;
|
||||
proceed with the normal connection
|
||||
select * from t1;
|
||||
c1
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@ basedir VALUE
|
|||
server_id VALUE
|
||||
skip-stack-trace VALUE
|
||||
skip-innodb VALUE
|
||||
skip-bdb VALUE
|
||||
skip-ndbcluster VALUE
|
||||
skip-bdb VALUE
|
||||
SHOW INSTANCE OPTIONS mysqld2;
|
||||
option_name value
|
||||
instance_name VALUE
|
||||
|
|
@ -42,8 +42,8 @@ basedir VALUE
|
|||
server_id VALUE
|
||||
skip-stack-trace VALUE
|
||||
skip-innodb VALUE
|
||||
skip-bdb VALUE
|
||||
skip-ndbcluster VALUE
|
||||
skip-bdb VALUE
|
||||
START INSTANCE mysqld2;
|
||||
Success: the process has been started.
|
||||
STOP INSTANCE mysqld2;
|
||||
|
|
|
|||
|
|
@ -737,6 +737,7 @@ select table_schema,table_name, column_name from
|
|||
information_schema.columns
|
||||
where data_type = 'longtext';
|
||||
table_schema table_name column_name
|
||||
information_schema COLUMNS COLUMN_DEFAULT
|
||||
information_schema COLUMNS COLUMN_TYPE
|
||||
information_schema ROUTINES ROUTINE_DEFINITION
|
||||
information_schema ROUTINES SQL_MODE
|
||||
|
|
@ -1240,3 +1241,16 @@ WHERE table_name=(SELECT MAX(table_name)
|
|||
FROM information_schema.tables);
|
||||
table_name
|
||||
VIEWS
|
||||
DROP TABLE IF EXISTS bug23037;
|
||||
DROP FUNCTION IF EXISTS get_value;
|
||||
SELECT COLUMN_NAME, MD5(COLUMN_DEFAULT), LENGTH(COLUMN_DEFAULT) FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='bug23037';
|
||||
COLUMN_NAME MD5(COLUMN_DEFAULT) LENGTH(COLUMN_DEFAULT)
|
||||
fld1 7cf7a6782be951a1f2464a350da926a5 65532
|
||||
SELECT MD5(get_value());
|
||||
MD5(get_value())
|
||||
7cf7a6782be951a1f2464a350da926a5
|
||||
SELECT COLUMN_NAME, MD5(COLUMN_DEFAULT), LENGTH(COLUMN_DEFAULT), COLUMN_DEFAULT=get_value() FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='bug23037';
|
||||
COLUMN_NAME MD5(COLUMN_DEFAULT) LENGTH(COLUMN_DEFAULT) COLUMN_DEFAULT=get_value()
|
||||
fld1 7cf7a6782be951a1f2464a350da926a5 65532 1
|
||||
DROP TABLE bug23037;
|
||||
DROP FUNCTION get_value;
|
||||
|
|
|
|||
|
|
@ -104,6 +104,14 @@ SELECT `id1` FROM `t1` WHERE `id1` NOT IN (SELECT `id1` FROM `t2` WHERE `id2` =
|
|||
id1
|
||||
2
|
||||
DROP TABLE t1, t2;
|
||||
create table t1 (c1 int) engine=innodb;
|
||||
handler t1 open;
|
||||
handler t1 read first;
|
||||
c1
|
||||
Before and after comparison
|
||||
0
|
||||
drop table t1;
|
||||
End of 4.1 tests
|
||||
create table t1m (a int) engine=myisam;
|
||||
create table t1i (a int) engine=innodb;
|
||||
create table t2m (a int) engine=myisam;
|
||||
|
|
@ -353,6 +361,12 @@ id select_type table type possible_keys key key_len ref rows Extra
|
|||
1 SIMPLE t2 index NULL fkey 5 NULL 5 Using index
|
||||
1 SIMPLE t1 eq_ref PRIMARY PRIMARY 4 test.t2.fkey 1 Using where
|
||||
DROP TABLE t1,t2;
|
||||
create table t1(f1 varchar(800) binary not null, key(f1)) engine = innodb
|
||||
character set utf8 collate utf8_general_ci;
|
||||
Warnings:
|
||||
Warning 1071 Specified key was too long; max key length is 765 bytes
|
||||
insert into t1 values('aaa');
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (a INT PRIMARY KEY, b INT, c FLOAT, KEY b(b)) ENGINE = INNODB;
|
||||
INSERT INTO t1 VALUES ( 1 , 1 , 1);
|
||||
INSERT INTO t1 SELECT a + 1 , MOD(a + 1 , 20), 1 FROM t1;
|
||||
|
|
@ -369,3 +383,4 @@ EXPLAIN SELECT SQL_BIG_RESULT b, SUM(c) FROM t1 GROUP BY b;
|
|||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 ALL NULL NULL NULL NULL 128 Using filesort
|
||||
DROP TABLE t1;
|
||||
End of 5.0 tests
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ start transaction;
|
|||
select f1();
|
||||
f1()
|
||||
100
|
||||
update t1 set col2=0 where col1=1;
|
||||
update t1 set col2=0 where col1=1;
|
||||
select * from t1;
|
||||
col1 col2
|
||||
1 100
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ create table t2 (id int unsigned not null);
|
|||
insert into t2 select id from t1;
|
||||
create table t3 (kill_id int);
|
||||
insert into t3 values(connection_id());
|
||||
select id from t1 where id in (select distinct id from t2);
|
||||
select id from t1 where id in (select distinct id from t2);
|
||||
select ((@id := kill_id) - kill_id) from t3;
|
||||
((@id := kill_id) - kill_id)
|
||||
0
|
||||
|
|
@ -32,7 +32,7 @@ drop table t1, t2, t3;
|
|||
select get_lock("a", 10);
|
||||
get_lock("a", 10)
|
||||
1
|
||||
select get_lock("a", 10);
|
||||
select get_lock("a", 10);
|
||||
get_lock("a", 10)
|
||||
NULL
|
||||
select 1;
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ drop table if exists t1,t2;
|
|||
create table t1(n int);
|
||||
insert into t1 values (1);
|
||||
lock tables t1 write;
|
||||
update low_priority t1 set n = 4;
|
||||
select n from t1;
|
||||
update low_priority t1 set n = 4;
|
||||
select n from t1;
|
||||
unlock tables;
|
||||
n
|
||||
4
|
||||
|
|
@ -11,8 +11,8 @@ drop table t1;
|
|||
create table t1(n int);
|
||||
insert into t1 values (1);
|
||||
lock tables t1 read;
|
||||
update low_priority t1 set n = 4;
|
||||
select n from t1;
|
||||
update low_priority t1 set n = 4;
|
||||
select n from t1;
|
||||
unlock tables;
|
||||
n
|
||||
1
|
||||
|
|
@ -23,7 +23,7 @@ insert into t1 values(1,1);
|
|||
insert into t1 values(2,2);
|
||||
insert into t2 values(1,2);
|
||||
lock table t1 read;
|
||||
update t1,t2 set c=a where b=d;
|
||||
update t1,t2 set c=a where b=d;
|
||||
select c from t2;
|
||||
c
|
||||
2
|
||||
|
|
@ -32,7 +32,7 @@ drop table t2;
|
|||
create table t1 (a int);
|
||||
create table t2 (a int);
|
||||
lock table t1 write, t2 write;
|
||||
insert t1 select * from t2;
|
||||
insert t1 select * from t2;
|
||||
drop table t2;
|
||||
ERROR 42S02: Table 'test.t2' doesn't exist
|
||||
drop table t1;
|
||||
|
|
@ -45,7 +45,7 @@ unlock tables;
|
|||
drop table t1;
|
||||
CREATE DATABASE mysqltest_1;
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
DROP DATABASE mysqltest_1;
|
||||
DROP DATABASE mysqltest_1;
|
||||
DROP DATABASE mysqltest_1;
|
||||
ERROR HY000: Can't execute the query because you have a conflicting read lock
|
||||
UNLOCK TABLES;
|
||||
|
|
@ -55,7 +55,7 @@ use mysql;
|
|||
LOCK TABLES columns_priv WRITE, db WRITE, host WRITE, user WRITE;
|
||||
FLUSH TABLES;
|
||||
use mysql;
|
||||
SELECT user.Select_priv FROM user, db WHERE user.user = db.user LIMIT 1;
|
||||
SELECT user.Select_priv FROM user, db WHERE user.user = db.user LIMIT 1;
|
||||
OPTIMIZE TABLES columns_priv, db, host, user;
|
||||
Table Op Msg_type Msg_text
|
||||
mysql.columns_priv optimize status OK
|
||||
|
|
@ -69,14 +69,14 @@ use test;
|
|||
use test;
|
||||
CREATE TABLE t1 (c1 int);
|
||||
LOCK TABLE t1 WRITE;
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
CREATE TABLE t2 (c1 int);
|
||||
UNLOCK TABLES;
|
||||
UNLOCK TABLES;
|
||||
DROP TABLE t1, t2;
|
||||
CREATE TABLE t1 (c1 int);
|
||||
LOCK TABLE t1 WRITE;
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
CREATE TABLE t2 AS SELECT * FROM t1;
|
||||
ERROR HY000: Table 't2' was not locked with LOCK TABLES
|
||||
UNLOCK TABLES;
|
||||
|
|
@ -84,7 +84,7 @@ UNLOCK TABLES;
|
|||
DROP TABLE t1;
|
||||
create table t1 (f1 int(12) unsigned not null auto_increment, primary key(f1)) engine=innodb;
|
||||
lock tables t1 write;
|
||||
alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; //
|
||||
alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; //
|
||||
alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; //
|
||||
alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; alter table t1 auto_increment=0; //
|
||||
unlock tables;
|
||||
drop table t1;
|
||||
|
|
|
|||
|
|
@ -195,7 +195,7 @@ select (@before:=unix_timestamp())*0;
|
|||
(@before:=unix_timestamp())*0
|
||||
0
|
||||
begin;
|
||||
select * from t1 for update;
|
||||
select * from t1 for update;
|
||||
insert into t2 values (20);
|
||||
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||
select (@after:=unix_timestamp())*0;
|
||||
|
|
|
|||
|
|
@ -509,8 +509,8 @@ create table t2 (a int);
|
|||
insert into t2 values (10), (20), (30);
|
||||
create view v1 as select a as b, a/10 as a from t2;
|
||||
lock table t1 write;
|
||||
alter table t1 add column c int default 100 after a;
|
||||
update t1, v1 set t1.b=t1.a+t1.b+v1.b where t1.a=v1.a;
|
||||
alter table t1 add column c int default 100 after a;
|
||||
update t1, v1 set t1.b=t1.a+t1.b+v1.b where t1.a=v1.a;
|
||||
unlock tables;
|
||||
select * from t1;
|
||||
a c b
|
||||
|
|
|
|||
|
|
@ -149,4 +149,33 @@ ERROR at line 1: USE must be followed by a database name
|
|||
\\
|
||||
';
|
||||
';
|
||||
create table t17583 (a int);
|
||||
insert into t17583 (a) values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
insert into t17583 select a from t17583;
|
||||
select count(*) from t17583;
|
||||
count(*)
|
||||
1280
|
||||
drop table t17583;
|
||||
Test connect without db- or host-name => reconnect
|
||||
Test connect with dbname only => new dbname, old hostname
|
||||
ERROR 1064 (42000) at line 1: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'connecttest' at line 1
|
||||
Test connect with _invalid_ dbname only => new invalid dbname, old hostname
|
||||
ERROR 1049 (42000) at line 1: Unknown database 'invalid'
|
||||
ERROR 1049 (42000) at line 1: Unknown database 'invalid'
|
||||
Test connect with dbname + hostname
|
||||
Test connect with dbname + _invalid_ hostname
|
||||
ERROR 2005 (HY000) at line 1: Unknown MySQL server host 'invalid_hostname' (errno)
|
||||
ERROR 2005 (HY000) at line 1: Unknown MySQL server host 'invalid_hostname' (errno)
|
||||
The commands reported in the bug report
|
||||
ERROR 2005 (HY000) at line 1: Unknown MySQL server host 'cyril has found a bug :)XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' (errno)
|
||||
Too long dbname
|
||||
ERROR 1049 (42000) at line 1: Unknown database 'test_really_long_dbnamexxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
|
||||
Too long hostname
|
||||
ERROR 2005 (HY000) at line 1: Unknown MySQL server host 'cyrils_superlonghostnameXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' (errno)
|
||||
End of 5.0 tests
|
||||
|
|
|
|||
|
|
@ -1,21 +1,4 @@
|
|||
drop table if exists t1;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't1'
|
||||
drop table if exists t2;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't2'
|
||||
drop table if exists t3;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't3'
|
||||
drop table if exists t4;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't4'
|
||||
drop table if exists t5;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't5'
|
||||
drop table if exists t6;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't6'
|
||||
drop table if exists t1, t2, t3, t4, t5, t6;
|
||||
create table t1 (id int(8), name varchar(32));
|
||||
create table t2 (id int(8), name varchar(32)) ENGINE="MyISAM";
|
||||
create table t3 (id int(8), name varchar(32)) ENGINE="MEMORY";
|
||||
|
|
|
|||
|
|
@ -3196,5 +3196,27 @@ UNLOCK TABLES;
|
|||
|
||||
DROP TABLE `t1`;
|
||||
#
|
||||
# Bug #19745: mysqldump --xml produces invalid xml
|
||||
#
|
||||
DROP TABLE IF EXISTS t1;
|
||||
CREATE TABLE t1 (f1 int(10), data MEDIUMBLOB);
|
||||
INSERT INTO t1 VALUES(1,0xff00fef0);
|
||||
<?xml version="1.0"?>
|
||||
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<database name="test">
|
||||
<table_structure name="t1">
|
||||
<field Field="f1" Type="int(10)" Null="YES" Key="" Extra="" />
|
||||
<field Field="data" Type="mediumblob" Null="YES" Key="" Extra="" />
|
||||
</table_structure>
|
||||
<table_data name="t1">
|
||||
<row>
|
||||
<field name="f1">1</field>
|
||||
<field name="data" xsi:type="xs:hexBinary">FF00FEF0</field>
|
||||
</row>
|
||||
</table_data>
|
||||
</database>
|
||||
</mysqldump>
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# End of 5.0 tests
|
||||
#
|
||||
|
|
|
|||
|
|
@ -152,8 +152,38 @@ mysqltest: At line 1: Missing delimiter
|
|||
mysqltest: At line 1: End of line junk detected: "sleep 7
|
||||
# Another comment
|
||||
"
|
||||
mysqltest: At line 1: Missing delimiter
|
||||
mysqltest: At line 1: Missing delimiter
|
||||
mysqltest: At line 1: End of line junk detected: "disconnect default
|
||||
|
||||
#
|
||||
# comment
|
||||
# comment2
|
||||
|
||||
# comment 3
|
||||
--disable_query_log
|
||||
"
|
||||
mysqltest: At line 1: End of line junk detected: "disconnect default # comment
|
||||
# comment part2
|
||||
|
||||
# comment 3
|
||||
--disable_query_log
|
||||
"
|
||||
mysqltest: At line 1: Extra delimiter ";" found
|
||||
mysqltest: At line 1: Extra delimiter ";" found
|
||||
mysqltest: At line 1: Missing argument(s) to 'error'
|
||||
mysqltest: At line 1: Missing argument(s) to 'error'
|
||||
mysqltest: At line 1: The sqlstate definition must start with an uppercase S
|
||||
mysqltest: At line 1: The error name definition must start with an uppercase E
|
||||
mysqltest: At line 1: Invalid argument to error: '9eeeee' - the errno may only consist of digits[0-9]
|
||||
mysqltest: At line 1: Invalid argument to error: '1sssss' - the errno may only consist of digits[0-9]
|
||||
mysqltest: At line 1: The sqlstate must be exactly 5 chars long
|
||||
mysqltest: At line 1: The sqlstate may only consist of digits[0-9] and _uppercase_ letters
|
||||
mysqltest: At line 1: The sqlstate must be exactly 5 chars long
|
||||
mysqltest: At line 1: Unknown SQL error name 'E9999'
|
||||
mysqltest: At line 1: Invalid argument to error: '999e9' - the errno may only consist of digits[0-9]
|
||||
mysqltest: At line 1: Invalid argument to error: '9b' - the errno may only consist of digits[0-9]
|
||||
mysqltest: At line 1: Too many errorcodes specified
|
||||
MySQL
|
||||
"MySQL"
|
||||
MySQL: The world''s most popular open source database
|
||||
|
|
@ -168,8 +198,8 @@ source database
|
|||
- most popular open
|
||||
- source database
|
||||
- MySQL: The world''s
|
||||
-- most popular open
|
||||
-- source database
|
||||
-- most popular
|
||||
-- open source database
|
||||
# MySQL: The
|
||||
--world''s
|
||||
# most popular
|
||||
|
|
@ -195,8 +225,8 @@ source database
|
|||
# source database
|
||||
-- MySQL: The
|
||||
-- world''s most
|
||||
-- popular open
|
||||
-- source database
|
||||
-- popular
|
||||
-- open source database
|
||||
# MySQL: The
|
||||
- world''s most
|
||||
-- popular open
|
||||
|
|
@ -224,12 +254,11 @@ banana = banana
|
|||
Not a banana: ba\$cat\$cat
|
||||
mysqltest: At line 1: Missing arguments to let
|
||||
mysqltest: At line 1: Missing variable name in let
|
||||
mysqltest: At line 1: Variable name in hi=hi does not start with '$'
|
||||
mysqltest: At line 1: Missing assignment operator in let
|
||||
mysqltest: At line 1: Missing assignment operator in let
|
||||
mysqltest: At line 1: Missing assignment operator in let
|
||||
mysqltest: At line 1: Missing variable name in let
|
||||
mysqltest: At line 1: Variable name in =hi does not start with '$'
|
||||
mysqltest: At line 1: Missing variable name in let
|
||||
mysqltest: At line 1: Missing assignment operator in let
|
||||
# Execute: --echo # <whatever> success: $success
|
||||
# <whatever> success: 1
|
||||
|
|
@ -240,7 +269,7 @@ mysqltest: At line 1: Missing assignment operator in let
|
|||
1
|
||||
# Execute: echo $success ;
|
||||
1
|
||||
mysqltest: At line 1: Missing file name in source
|
||||
mysqltest: At line 1: Missing required argument 'filename' to command 'source'
|
||||
mysqltest: At line 1: Could not open file ./non_existingFile
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/recursive.sql": At line 1: Source directives are nesting too deep
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/error.sql": At line 1: query 'garbage ' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'garbage' at line 1
|
||||
|
|
@ -333,16 +362,16 @@ Counter is greater than 0, (counter=10)
|
|||
Counter is not 0, (counter=0)
|
||||
1
|
||||
Testing while with not
|
||||
mysqltest: In included file "./include/mysqltest_while.inc": At line 64: Nesting too deeply
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest_while.inc": At line 64: Nesting too deeply
|
||||
mysqltest: At line 1: missing '(' in while
|
||||
mysqltest: At line 1: missing ')' in while
|
||||
mysqltest: At line 1: Missing '{' after while. Found "dec $i"
|
||||
mysqltest: At line 1: Stray '}' - end of block before beginning
|
||||
mysqltest: At line 1: Stray 'end' command - end of block before beginning
|
||||
mysqltest: At line 1: query '' failed: 1065: Query was empty
|
||||
mysqltest: At line 1: query '{' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '{' at line 1
|
||||
mysqltest: At line 1: Missing '{' after while. Found "echo hej"
|
||||
mysqltest: At line 3: Missing end of block
|
||||
mysqltest: At line 1: Missing newline between while and '{'
|
||||
mysqltest: At line 3: Missing end of block
|
||||
mysqltest: At line 1: missing '(' in if
|
||||
mysqltest: At line 1: Stray 'end' command - end of block before beginning
|
||||
select "b" bs col1, "c" bs col2;
|
||||
|
|
@ -372,17 +401,15 @@ mysqltest: At line 1: Wrong column number to replace_column in 'replace_column 1
|
|||
mysqltest: At line 1: Invalid integer argument "10!"
|
||||
mysqltest: At line 1: End of line junk detected: "!"
|
||||
mysqltest: At line 1: Invalid integer argument "a"
|
||||
mysqltest: At line 1: Syntax error in connect - expected '(' found 'mysqltest: At line 1: Missing connection host
|
||||
mysqltest: At line 1: Missing connection host
|
||||
mysqltest: At line 1: Missing connection user
|
||||
mysqltest: At line 1: Missing connection user
|
||||
mysqltest: At line 1: Missing connection password
|
||||
mysqltest: At line 1: Missing connection db
|
||||
mysqltest: At line 1: Could not open connection 'con2': 1049 Unknown database 'illegal_db'
|
||||
mysqltest: At line 1: Missing required argument 'connection name' to command 'connect'
|
||||
mysqltest: At line 1: Missing required argument 'connection name' to command 'connect'
|
||||
mysqltest: At line 1: Missing required argument 'host' to command 'connect'
|
||||
mysqltest: At line 1: Missing required argument 'host' to command 'connect'
|
||||
mysqltest: At line 1: query 'connect con2,localhost,root,,illegal_db' failed: 1049: Unknown database 'illegal_db'
|
||||
mysqltest: At line 1: Illegal argument for port: 'illegal_port'
|
||||
mysqltest: At line 1: Illegal option to connect: SMTP
|
||||
OK
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 7: Connection limit exhausted - increase MAX_CONS in mysqltest.c
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 7: Connection limit exhausted, you can have max 128 connections
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 3: connection 'test_con1' not found in connection pool
|
||||
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 2: Connection test_con1 already exists
|
||||
connect(localhost,root,,test,MASTER_PORT,MASTER_SOCKET);
|
||||
|
|
@ -450,3 +477,47 @@ sleep;
|
|||
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'sleep' at line 1
|
||||
;
|
||||
ERROR 42000: Query was empty
|
||||
select "b" as col1, "c" as col2;
|
||||
col1 col2
|
||||
b c
|
||||
select "b" as col1, "b" as col2, "c" as col3;
|
||||
col1 col2 col3
|
||||
b b c
|
||||
seled "b" bs col1, "d" bs col2;
|
||||
col1 col2
|
||||
b d
|
||||
select "raspberry and strawberry","blackberry","tomato";
|
||||
raspberry and strawberry blackberry tomato
|
||||
raspberry and strawberry blackberry tomato
|
||||
mysqltest: At line 1: Error parsing replace_regex "a"
|
||||
mysqltest: At line 1: Error parsing replace_regex "a;"
|
||||
mysqltest: At line 1: Error parsing replace_regex "a"
|
||||
mysqltest: At line 1: Error parsing replace_regex "a "
|
||||
mysqltest: At line 1: Error parsing replace_regex "a b"
|
||||
mysqltest: At line 1: Error parsing replace_regex "/a b c"
|
||||
mysqltest: At line 1: Error parsing replace_regex "/a /b c "
|
||||
create table t1 (a int, b int);
|
||||
insert into t1 values (1,3);
|
||||
insert into t1 values (2,4);
|
||||
select * from t1;
|
||||
a D
|
||||
1 1
|
||||
1 4
|
||||
drop table t1;
|
||||
mysqltest: At line 1: Missing required argument 'filename' to command 'remove_file'
|
||||
mysqltest: At line 1: Missing required argument 'filename' to command 'write_file'
|
||||
mysqltest: At line 1: End of file encountered before 'EOF' delimiter was found
|
||||
mysqltest: At line 1: End of line junk detected: "write_file filename ";
|
||||
"
|
||||
mysqltest: At line 1: Missing required argument 'filename' to command 'file_exists'
|
||||
mysqltest: At line 1: Missing required argument 'from_file' to command 'copy_file'
|
||||
mysqltest: At line 1: Missing required argument 'to_file' to command 'copy_file'
|
||||
hello
|
||||
hello
|
||||
hello
|
||||
mysqltest: At line 1: Max delimiter length(16) exceeded
|
||||
hello
|
||||
hello
|
||||
mysqltest: At line 1: test of die
|
||||
Some output
|
||||
End of tests
|
||||
|
|
|
|||
|
|
@ -1476,4 +1476,21 @@ i
|
|||
DEALLOCATE PREPARE stmt;
|
||||
DROP TABLE t1, t2;
|
||||
DROP PROCEDURE IF EXISTS p1;
|
||||
flush status;
|
||||
prepare sq from 'show status like "slow_queries"';
|
||||
execute sq;
|
||||
Variable_name Value
|
||||
Slow_queries 0
|
||||
prepare no_index from 'select 1 from information_schema.tables limit 1';
|
||||
execute sq;
|
||||
Variable_name Value
|
||||
Slow_queries 0
|
||||
execute no_index;
|
||||
1
|
||||
1
|
||||
execute sq;
|
||||
Variable_name Value
|
||||
Slow_queries 1
|
||||
deallocate prepare no_index;
|
||||
deallocate prepare sq;
|
||||
End of 5.0 tests.
|
||||
|
|
|
|||
|
|
@ -130,3 +130,36 @@ prepare st_18492 from 'select * from t1 where 3 in (select (1+1) union select 1)
|
|||
execute st_18492;
|
||||
a
|
||||
drop table t1;
|
||||
create table t1 (a int, b varchar(4));
|
||||
create table t2 (a int, b varchar(4), primary key(a));
|
||||
prepare stmt1 from 'insert into t1 (a, b) values (?, ?)';
|
||||
prepare stmt2 from 'insert into t2 (a, b) values (?, ?)';
|
||||
set @intarg= 11;
|
||||
set @varchararg= '2222';
|
||||
execute stmt1 using @intarg, @varchararg;
|
||||
execute stmt2 using @intarg, @varchararg;
|
||||
set @intarg= 12;
|
||||
execute stmt1 using @intarg, @UNDEFINED;
|
||||
execute stmt2 using @intarg, @UNDEFINED;
|
||||
set @intarg= 13;
|
||||
execute stmt1 using @UNDEFINED, @varchararg;
|
||||
execute stmt2 using @UNDEFINED, @varchararg;
|
||||
ERROR 23000: Column 'a' cannot be null
|
||||
set @intarg= 14;
|
||||
set @nullarg= Null;
|
||||
execute stmt1 using @UNDEFINED, @nullarg;
|
||||
execute stmt2 using @nullarg, @varchararg;
|
||||
ERROR 23000: Column 'a' cannot be null
|
||||
select * from t1;
|
||||
a b
|
||||
11 2222
|
||||
12 NULL
|
||||
NULL 2222
|
||||
NULL NULL
|
||||
select * from t2;
|
||||
a b
|
||||
11 2222
|
||||
12 NULL
|
||||
drop table t1;
|
||||
drop table t2;
|
||||
End of 5.0 tests.
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -326,7 +326,7 @@ insert into t1 values(3);
|
|||
set i_var = sleep(3);
|
||||
return 0;
|
||||
end;|
|
||||
select f1();
|
||||
select f1();
|
||||
select sleep(4);
|
||||
sleep(4)
|
||||
0
|
||||
|
|
|
|||
|
|
@ -665,6 +665,16 @@ OR ((pk4 =1) AND (((pk1 IN ( 7, 2, 1 ))) OR (pk1 =522)) AND ((pk2 IN ( 0, 2635))
|
|||
pk1 pk2 pk3 pk4 filler
|
||||
2621 2635 1000015 0 filler
|
||||
drop table t1, t2;
|
||||
create table t1(a char(2), key(a(1)));
|
||||
insert into t1 values ('x'), ('xx');
|
||||
explain select a from t1 where a > 'x';
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 range a a 2 NULL 2 Using where
|
||||
select a from t1 where a > 'x';
|
||||
a
|
||||
xx
|
||||
drop table t1;
|
||||
End of 4.1 tests
|
||||
CREATE TABLE t1 (
|
||||
id int(11) NOT NULL auto_increment,
|
||||
status varchar(20),
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ Note 1051 Unknown table 't4'
|
|||
CREATE TABLE t1 (a int);
|
||||
CREATE TABLE t3 (a int);
|
||||
FLUSH TABLES WITH READ LOCK;
|
||||
RENAME TABLE t1 TO t2, t3 to t4;
|
||||
RENAME TABLE t1 TO t2, t3 to t4;
|
||||
show tables;
|
||||
Tables_in_test
|
||||
t1
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ create table t2(id int);
|
|||
insert into t2 values(connection_id());
|
||||
create temporary table t3(n int);
|
||||
insert into t3 select get_lock('crash_lock%20C', 1) from t2;
|
||||
update t1 set n = n + get_lock('crash_lock%20C', 2);
|
||||
update t1 set n = n + get_lock('crash_lock%20C', 2);
|
||||
select (@id := id) - id from t2;
|
||||
(@id := id) - id
|
||||
0
|
||||
|
|
|
|||
|
|
@ -1,14 +0,0 @@
|
|||
reset master;
|
||||
reset slave;
|
||||
start slave;
|
||||
show binary logs;
|
||||
Log_name
|
||||
master-bin.000001
|
||||
master-bin.000002
|
||||
drop table if exists t1;
|
||||
create table t1(n int);
|
||||
insert into t1 values (3351);
|
||||
select * from t1;
|
||||
n
|
||||
3351
|
||||
drop table t1;
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
reset master;
|
||||
change master to master_host='127.0.0.1',master_port=9307, master_user='root';
|
||||
start slave;
|
||||
create temporary table t1 (a int);
|
||||
create temporary table t1 (a int);
|
||||
show status like 'slave_open_temp_tables';
|
||||
Variable_name Value
|
||||
Slave_open_temp_tables 2
|
||||
create temporary table t1 (a int);
|
||||
create temporary table t1 (a int);
|
||||
show status like 'slave_open_temp_tables';
|
||||
Variable_name Value
|
||||
Slave_open_temp_tables 4
|
||||
stop slave;
|
||||
insert into t1 values(1);
|
||||
create table t2 as select * from t1;
|
||||
start slave;
|
||||
show status like 'slave_open_temp_tables';
|
||||
Variable_name Value
|
||||
Slave_open_temp_tables 4
|
||||
select * from t2;
|
||||
a
|
||||
1
|
||||
drop table t2;
|
||||
|
|
@ -20,7 +20,7 @@ create table t2 (a int primary key);
|
|||
insert into t2 values(1);
|
||||
create table t3 (id int);
|
||||
insert into t3 values(connection_id());
|
||||
update t2 set a = a + 1 + get_lock('crash_lock%20C', 10);
|
||||
update t2 set a = a + 1 + get_lock('crash_lock%20C', 10);
|
||||
select (@id := id) - id from t3;
|
||||
(@id := id) - id
|
||||
0
|
||||
|
|
|
|||
|
|
@ -1,34 +0,0 @@
|
|||
stop slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
start slave;
|
||||
show variables like 'rpl_recovery_rank';
|
||||
Variable_name Value
|
||||
rpl_recovery_rank 1
|
||||
show status like 'Rpl_status';
|
||||
Variable_name Value
|
||||
Rpl_status AUTH_MASTER
|
||||
create table t1(n int);
|
||||
drop table t1;
|
||||
show variables like 'rpl_recovery_rank';
|
||||
Variable_name Value
|
||||
rpl_recovery_rank 2
|
||||
show status like 'Rpl_status';
|
||||
Variable_name Value
|
||||
Rpl_status ACTIVE_SLAVE
|
||||
start slave;
|
||||
show variables like 'rpl_recovery_rank';
|
||||
Variable_name Value
|
||||
rpl_recovery_rank 3
|
||||
show status like 'Rpl_status';
|
||||
Variable_name Value
|
||||
Rpl_status ACTIVE_SLAVE
|
||||
start slave;
|
||||
show variables like 'rpl_recovery_rank';
|
||||
Variable_name Value
|
||||
rpl_recovery_rank 4
|
||||
show status like 'Rpl_status';
|
||||
Variable_name Value
|
||||
Rpl_status ACTIVE_SLAVE
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
reset master;
|
||||
drop table if exists t1;
|
||||
create table t1 type=HEAP select 10 as a;
|
||||
insert into t1 values(11);
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use `test`; create table t1 type=HEAP select 10 as a
|
||||
master-bin.001 154 Query 1 154 use `test`; insert into t1 values(11)
|
||||
reset slave;
|
||||
start slave;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(2) NOT NULL default '0'
|
||||
) TYPE=HEAP
|
||||
select * from t1;
|
||||
a
|
||||
10
|
||||
11
|
||||
select * from t1;
|
||||
a
|
||||
select * from t1 limit 10;
|
||||
a
|
||||
show binlog events in 'master-bin.002' from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.002 79 Query 1 79 use `test`; DELETE FROM `test`.`t1`
|
||||
select * from t1;
|
||||
a
|
||||
drop table t1;
|
||||
|
|
@ -12,7 +12,7 @@ id select_type table type possible_keys key key_len ref rows Extra
|
|||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
Warnings:
|
||||
Note 1003 select master_pos_wait(_latin1'master-bin.999999',0,2) AS `master_pos_wait('master-bin.999999',0,2)`
|
||||
select master_pos_wait('master-bin.999999',0);
|
||||
select master_pos_wait('master-bin.999999',0);
|
||||
stop slave sql_thread;
|
||||
master_pos_wait('master-bin.999999',0)
|
||||
NULL
|
||||
|
|
|
|||
|
|
@ -71,8 +71,6 @@ get_lock("bug12480",2)
|
|||
1
|
||||
create table t1 (a datetime,b datetime, c datetime);
|
||||
drop function if exists bug12480;
|
||||
Warnings:
|
||||
Note 1305 FUNCTION bug12480 does not exist
|
||||
create function bug12480() returns datetime
|
||||
begin
|
||||
set @a=get_lock("bug12480",2);
|
||||
|
|
|
|||
|
|
@ -520,6 +520,7 @@ t1 NULL NULL NULL NULL # # # # NULL NULL NULL NULL NULL NULL NULL NULL Incorrect
|
|||
show create table t1;
|
||||
ERROR HY000: Incorrect information in file: './test/t1.frm'
|
||||
drop table t1;
|
||||
End of 4.1 tests
|
||||
CREATE TABLE txt1(a int);
|
||||
CREATE TABLE tyt2(a int);
|
||||
CREATE TABLE urkunde(a int);
|
||||
|
|
@ -629,3 +630,19 @@ SHOW TABLES FROM no_such_database;
|
|||
ERROR 42000: Unknown database 'no_such_database'
|
||||
SHOW COLUMNS FROM no_such_table;
|
||||
ERROR 42S02: Table 'test.no_such_table' doesn't exist
|
||||
flush status;
|
||||
show status like 'slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 0
|
||||
show tables;
|
||||
Tables_in_test
|
||||
show status like 'slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 0
|
||||
select 1 from information_schema.tables limit 1;
|
||||
1
|
||||
1
|
||||
show status like 'slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 1
|
||||
End of 5.0 tests
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ create procedure bug9486()
|
|||
update t1, t2 set val= 1 where id1=id2;
|
||||
call bug9486();
|
||||
lock tables t2 write;
|
||||
call bug9486();
|
||||
call bug9486();
|
||||
show processlist;
|
||||
Id User Host db Command Time State Info
|
||||
# root localhost test Sleep # NULL
|
||||
|
|
@ -77,7 +77,7 @@ select * from t1;
|
|||
end|
|
||||
use test;
|
||||
lock table t1 write;
|
||||
call p2();
|
||||
call p2();
|
||||
use test;
|
||||
drop procedure p1;
|
||||
create procedure p1() select * from t1;
|
||||
|
|
|
|||
|
|
@ -85,8 +85,7 @@ flush status|
|
|||
flush query cache|
|
||||
delete from t1|
|
||||
drop procedure bug3583|
|
||||
drop table t1;
|
||||
#|
|
||||
drop table t1|
|
||||
drop procedure if exists bug6807|
|
||||
create procedure bug6807()
|
||||
begin
|
||||
|
|
|
|||
2159
mysql-test/r/ssl_des.result
Normal file
2159
mysql-test/r/ssl_des.result
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -2717,8 +2717,7 @@ select (1,2,3) = (select * from t1);
|
|||
ERROR 21000: Operand should contain 3 column(s)
|
||||
select (select * from t1) = (1,2,3);
|
||||
ERROR 21000: Operand should contain 2 column(s)
|
||||
drop table t1
|
||||
#;
|
||||
drop table t1;
|
||||
CREATE TABLE `t1` (
|
||||
`itemid` bigint(20) unsigned NOT NULL auto_increment,
|
||||
`sessionid` bigint(20) unsigned default NULL,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
drop table if exists t1;
|
||||
CREATE TABLE t1 (x1 int);
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -8,7 +8,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -16,7 +16,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -24,7 +24,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -32,7 +32,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -40,7 +40,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -48,7 +48,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -56,7 +56,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -64,7 +64,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -72,7 +72,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -80,7 +80,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -88,7 +88,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -96,7 +96,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -104,7 +104,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -112,7 +112,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -120,7 +120,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -128,7 +128,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -136,7 +136,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -144,7 +144,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
@ -152,7 +152,7 @@ t2 CREATE TABLE `t2` (
|
|||
`xx` int(11) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
|
|
|
|||
|
|
@ -978,8 +978,6 @@ t1 CREATE TABLE `t1` (
|
|||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
drop procedure if exists wg2;
|
||||
Warnings:
|
||||
Note 1305 PROCEDURE wg2 does not exist
|
||||
create procedure wg2()
|
||||
begin
|
||||
declare v int default 1;
|
||||
|
|
|
|||
|
|
@ -836,27 +836,27 @@ count(*)
|
|||
26
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 1
|
||||
Slow_queries 0
|
||||
select count(*) from t1 where b=13;
|
||||
count(*)
|
||||
10
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 3
|
||||
Slow_queries 1
|
||||
select count(*) from t1 where b=13 union select count(*) from t1 where a=7;
|
||||
count(*)
|
||||
10
|
||||
26
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 5
|
||||
Slow_queries 2
|
||||
select count(*) from t1 where a=7 union select count(*) from t1 where b=13;
|
||||
count(*)
|
||||
26
|
||||
10
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 7
|
||||
Slow_queries 3
|
||||
flush status;
|
||||
select a from t1 where b not in (1,2,3) union select a from t1 where b not in (4,5,6);
|
||||
a
|
||||
|
|
|
|||
|
|
@ -215,6 +215,7 @@ select @@version;
|
|||
select @@global.version;
|
||||
@@global.version
|
||||
#
|
||||
End of 4.1 tests
|
||||
set @first_var= NULL;
|
||||
create table t1 select @first_var;
|
||||
show create table t1;
|
||||
|
|
@ -301,3 +302,11 @@ select @var;
|
|||
@var
|
||||
3
|
||||
drop table t1;
|
||||
insert into city 'blah';
|
||||
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''blah'' at line 1
|
||||
SHOW COUNT(*) WARNINGS;
|
||||
@@session.warning_count
|
||||
1
|
||||
SHOW COUNT(*) ERRORS;
|
||||
@@session.error_count
|
||||
1
|
||||
|
|
|
|||
|
|
@ -1980,7 +1980,7 @@ v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VI
|
|||
drop view v1;
|
||||
drop table t1;
|
||||
set sql_mode='strict_all_tables';
|
||||
CREATE TABLE t1 (col1 INT NOT NULL, col2 INT NOT NULL) ENGINE = INNODB;
|
||||
CREATE TABLE t1 (col1 INT NOT NULL, col2 INT NOT NULL);
|
||||
CREATE VIEW v1 (vcol1) AS SELECT col1 FROM t1;
|
||||
CREATE VIEW v2 (vcol1) AS SELECT col1 FROM t1 WHERE col2 > 2;
|
||||
INSERT INTO t1 (col1) VALUES(12);
|
||||
|
|
@ -2032,7 +2032,7 @@ f3 f1
|
|||
1 3
|
||||
drop view v1;
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (f1 char) ENGINE = innodb;
|
||||
CREATE TABLE t1 (f1 char);
|
||||
INSERT INTO t1 VALUES ('A');
|
||||
CREATE VIEW v1 AS SELECT * FROM t1;
|
||||
INSERT INTO t1 VALUES('B');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue