summaryrefslogtreecommitdiff
path: root/mysql-test/t/insert.test
diff options
context:
space:
mode:
authorpem@mysql.com <>2003-09-24 11:29:38 +0200
committerpem@mysql.com <>2003-09-24 11:29:38 +0200
commit8d884c02bb2ca2f2b4bce6dccbaf69d6935e293d (patch)
tree4f2fa31d20ec4c9a54f602c624b20c1cf4ddf493 /mysql-test/t/insert.test
parentefd94f5ba972bb10d2d10fe46fc9153536941e92 (diff)
parentb8e4dc03d809838f6f589ef24089e52ea806da33 (diff)
downloadmariadb-git-8d884c02bb2ca2f2b4bce6dccbaf69d6935e293d.tar.gz
Merging 4.1 -> 5.0
Diffstat (limited to 'mysql-test/t/insert.test')
-rw-r--r--mysql-test/t/insert.test31
1 files changed, 31 insertions, 0 deletions
diff --git a/mysql-test/t/insert.test b/mysql-test/t/insert.test
index 9cc0bf8c46c..4a89ec15c57 100644
--- a/mysql-test/t/insert.test
+++ b/mysql-test/t/insert.test
@@ -76,3 +76,34 @@ use test_$1;
create table t1 (c int);
insert into test_$1.t1 set test_$1.t1.c = '1';
drop database test_$1;
+use test;
+--disable_warnings
+drop table if exists t1,t2,t3;
+--enable_warnings
+create table t1(id1 int not null auto_increment primary key, t char(12));
+create table t2(id2 int not null, t char(12));
+create table t3(id3 int not null, t char(12), index(id3));
+disable_query_log;
+let $1 = 100;
+while ($1)
+ {
+ let $2 = 5;
+ eval insert into t1(t) values ('$1');
+ while ($2)
+ {
+ eval insert into t2(id2,t) values ($1,'$2');
+ let $3 = 10;
+ while ($3)
+ {
+ eval insert into t3(id3,t) values ($1,'$2');
+ dec $3;
+ }
+ dec $2;
+ }
+ dec $1;
+ }
+enable_query_log;
+select count(*) from t2;
+insert into t2 select t1.* from t1, t2 t, t3 where t1.id1 = t.id2 and t.id2 = t3.id3;
+select count(*) from t2;
+drop table if exists t1,t2,t3;