~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/t/subselect3.test

  • Committer: Mark Atwood
  • Date: 2008-10-16 11:33:16 UTC
  • mto: (520.1.13 drizzle)
  • mto: This revision was merged to the branch mainline in revision 530.
  • Revision ID: mark@fallenpegasus.com-20081016113316-ff6jdt31ck90sjdh
an implemention of the errmsg plugin

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
insert into t3 values (NULL), (NULL);
57
57
flush status;
58
58
select a in (select max(ie) from t1 where oref=4 group by grp) from t3;
59
 
--replace_column 2 #
60
59
show status like 'Handler_read_rnd_next';
61
60
select ' ^ This must show 11' Z;
62
61
 
89
88
flush status;
90
89
select oref, a from t2 where a in (select a from t1 where oref=t2.oref);
91
90
# This will only show access to t2:
92
 
--replace_column 2 #
93
91
show status like '%Handler_read_rnd_next';
94
92
 
95
93
# Check that repeated NULL-scans are not cached (subq. is not correlated):
98
96
 
99
97
flush status;
100
98
select oref, a, a in (select a from t1 where oref=t2.oref) Z from t2;
101
 
--replace_column 2 #
102
99
show status like '%Handler_read%';
103
100
select 'No key lookups, seq reads: 29= 5 reads from t2 + 4 * 6 reads from t1.' Z;
104
101
 
618
615
 
619
616
create table t1 (a int, b decimal(13, 3)); 
620
617
insert into t1 values (1, 0.123);
621
 
--replace_result $DRIZZLETEST_VARDIR DRIZZLETEST_VARDIR
622
 
eval select a, (select max(b) from t1) into outfile "$DRIZZLETEST_VARDIR/subselect.out.file.1" from t1;
 
618
select a, (select max(b) from t1) into outfile "subselect.out.file.1" from t1;
623
619
delete from t1;
624
 
--replace_result $DRIZZLETEST_VARDIR DRIZZLETEST_VARDIR
625
 
eval load data infile "$DRIZZLETEST_VARDIR/subselect.out.file.1" into table t1;
 
620
load data infile "subselect.out.file.1" into table t1;
626
621
select * from t1;
627
622
drop table t1;
628
623