mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Merge mysql.com:/home/gluh/MySQL/Merge/5.0
into mysql.com:/home/gluh/MySQL/Merge/5.0-opt
This commit is contained in:
@@ -1839,4 +1839,26 @@ CHECK TABLE t1 EXTENDED;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 check status OK
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (id int NOT NULL, ref int NOT NULL, INDEX (id)) ENGINE=MyISAM;
|
||||
CREATE TABLE t2 LIKE t1;
|
||||
INSERT INTO t2 (id, ref) VALUES (1,3), (2,1), (3,2), (4,5), (4,4);
|
||||
INSERT INTO t1 SELECT * FROM t2;
|
||||
SELECT * FROM t1 AS a INNER JOIN t1 AS b USING (id) WHERE a.ref < b.ref;
|
||||
id ref ref
|
||||
4 4 5
|
||||
SELECT * FROM t1;
|
||||
id ref
|
||||
1 3
|
||||
2 1
|
||||
3 2
|
||||
4 5
|
||||
4 4
|
||||
DELETE FROM a USING t1 AS a INNER JOIN t1 AS b USING (id) WHERE a.ref < b.ref;
|
||||
SELECT * FROM t1;
|
||||
id ref
|
||||
1 3
|
||||
2 1
|
||||
3 2
|
||||
4 5
|
||||
DROP TABLE t1, t2;
|
||||
End of 5.0 tests
|
||||
|
||||
Reference in New Issue
Block a user