~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/t/union.test

  • Committer: Lee Bieber
  • Date: 2011-03-29 22:31:41 UTC
  • mfrom: (2257.1.3 build)
  • Revision ID: kalebral@gmail.com-20110329223141-yxc22h3l2he58sk0
Merge Andrew - 743842: Build failure using GCC 4.6
Merge Stewart - 738022: CachedDirectory silently fails to add entries if stat() fails
Merge Olaf - Common fwd: add copyright, add more declaration

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
--replace_column 9 #
40
40
explain select a,b from t1 union all select a,b from t2;
41
41
 
42
 
--error  1054
 
42
--error ER_BAD_FIELD_ERROR
43
43
explain select xx from t1 union select 1;
44
44
--error ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT
45
45
explain select a,b from t1 union select 1;
316
316
insert into t2 (group_name) values ('Group A');
317
317
insert into t2 (group_name) values ('Group B');
318
318
insert into t3 (user_id, group_id) values (1,1);
319
 
select 1 'is_in_group', a.user_name, c.group_name, b.id from t1 a, t3 b, t2 c where a.id = b.user_id and b.group_id = c.id UNION  select 0 'is_in_group', a.user_name, c.group_name, null from t1 a, t2 c;
 
319
select 1 'is_in_group', a.user_name, c.group_name, b.id from t1 a, t3 b, t2 c where a.id = b.user_id and b.group_id = c.id UNION  select 0 'is_in_group', a.user_name, c.group_name, null from t1 a CROSS JOIN t2 c;
320
320
drop table t3, t1, t2;
321
321
 
322
322
#
436
436
--replace_regex /ENGINE=[a-zA-Z]+/ENGINE=DEFAULT/
437
437
show create table t1;
438
438
drop table t1;
 
439
--error ER_BAD_FIELD_ERROR
439
440
create table t1 select _latin1"test" union select _latin1"testt" ;
 
441
--error ER_BAD_FIELD_ERROR
440
442
create table t1 select _utf8"test" union select _utf8"testt" ;
441
443
create table t1 select "test" union select "testt" ;
442
444
--replace_regex /ENGINE=[a-zA-Z]+/ENGINE=DEFAULT/
748
748
select concat('a', 'b' collate utf8_bin);
749
749
create table t1 (foo varchar(100)) collate=utf8_bin;
750
750
insert into t1 (foo) values ("foo");
751
 
--error ER_NO_SUCH_TABLE
 
751
--error ER_TABLE_UNKNOWN
752
752
select foo from t1 union select 'bar' as foo from dual;
753
753
select foo from t1 union select 'bar' as foo;
754
754
drop table t1;