diff options
author | unknown <bell@sanja.is.com.ua> | 2004-09-08 21:54:01 +0300 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2004-09-08 21:54:01 +0300 |
commit | b9826e10635e222ca758692c6788a5a449e10926 (patch) | |
tree | c8b6bdeb3236e4bacaa9793fd4a5dfd89645f984 /mysql-test/r/subselect_innodb.result | |
parent | 9b6ca7f3a516267422f4048d48ad1ce78a773c27 (diff) | |
download | mariadb-git-b9826e10635e222ca758692c6788a5a449e10926.tar.gz |
test case of bug#5220
Diffstat (limited to 'mysql-test/r/subselect_innodb.result')
-rw-r--r-- | mysql-test/r/subselect_innodb.result | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/mysql-test/r/subselect_innodb.result b/mysql-test/r/subselect_innodb.result index bbbc607b6f8..e8f6426f51b 100644 --- a/mysql-test/r/subselect_innodb.result +++ b/mysql-test/r/subselect_innodb.result @@ -106,3 +106,11 @@ a b 2 12 4 105 drop table t1, t2; +CREATE TABLE `t1` ( `unit` varchar(50) NOT NULL default '', `ingredient` varchar(50) NOT NULL default '') ENGINE=InnoDB DEFAULT CHARSET=latin1; +CREATE TABLE `t2` ( `ingredient` varchar(50) NOT NULL default '', `unit` varchar(50) NOT NULL default '', PRIMARY KEY (ingredient, unit)) ENGINE=InnoDB DEFAULT CHARSET=latin1; +INSERT INTO `t1` VALUES ('xx','yy'); +INSERT INTO `t2` VALUES ('yy','xx'); +SELECT R.unit, R.ingredient FROM t1 R WHERE R.ingredient IN (SELECT N.ingredient FROM t2 N WHERE N.unit = R.unit); +unit ingredient +xx yy +drop table t1, t2; |