~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/myisam/tests/t/basic.test

  • Committer: Brian Aker
  • Date: 2010-10-28 17:12:01 UTC
  • mfrom: (1887.1.3 merge)
  • Revision ID: brian@tangent.org-20101028171201-baj6l1bnntn1s4ad
Merge in POTFILES changes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
# Test problem with rows that are 65517-65520 bytes long
31
31
#
32
32
 
33
 
create temporary table t1 (a int not null auto_increment, b blob not null, primary key (a)) engine=myisam;
 
33
create table t1 (a int not null auto_increment, b blob not null, primary key (a));
34
34
 
35
35
let $1=100;
36
36
disable_query_log;
342
342
 
343
343
CREATE TEMPORARY TABLE t1 (a int not null, b int, c int, key(b), key(c), key(a,b), key(c,a)) ENGINE=MyISAM;
344
344
INSERT into t1 values (0, null, 0), (0, null, 1), (0, null, 2), (0, null,3), (1,1,4);
345
 
create temporary table t2 (a int not null, b int, c int, key(b), key(c), key(a)) engine=myisam;
 
345
create table t2 (a int not null, b int, c int, key(b), key(c), key(a));
346
346
INSERT into t2 values (1,1,1), (2,2,2);
347
347
alter table t1 ENGINE=MYISAM;
348
348
show index from t1;
361
361
# Test bug when updating a split dynamic row where keys are not changed
362
362
#
363
363
 
364
 
create temporary table t1 (a int not null auto_increment primary key, b varchar(255)) engine=myisam;
 
364
create table t1 (a int not null auto_increment primary key, b varchar(255));
365
365
insert into t1 (b) values (repeat('a',100)),(repeat('b',100)),(repeat('c',100));
366
366
update t1 set b=repeat(left(b,1),200) where a=1;
367
367
 
441
441
#
442
442
# Verify blob handling
443
443
#
444
 
create temporary table t1 (a blob) engine=myisam;
 
444
create table t1 (a blob);
445
445
insert into t1 values('a '),('a');
446
446
select concat(a,'.') from t1 where a='a';
447
447
select concat(a,'.') from t1 where a='a ';
453
453
#
454
454
# Test text and unique
455
455
#
456
 
create temporary table t1 (a int not null auto_increment primary key, b text not null, unique b (b(20))) engine=myisam;
 
456
create table t1 (a int not null auto_increment primary key, b text not null, unique b (b(20)));
457
457
insert into t1 (b) values ('a'),('b'),('c');
458
458
select concat(b,'.') from t1;
459
459
update t1 set b='b ' where a=2;
469
469
#
470
470
# Test keys with 0 segments. (Bug #3203)
471
471
#
472
 
create temporary table t1 (a int not null) engine=myisam;
473
 
create temporary table t2 (a int not null, primary key (a)) engine=myisam;
 
472
create table t1 (a int not null);
 
473
create table t2 (a int not null, primary key (a));
474
474
insert into t1 values (1);
475
475
insert into t2 values (1),(2);
476
476
select sql_big_result distinct t1.a from t1,t2 order by t2.a;
494
494
 
495
495
# End of 4.0 tests
496
496
 
497
 
create temporary table t1 (a int, b varchar(200), c text not null) engine=myisam;
498
 
create temporary table t2 (a int, b varchar(200), c text not null) engine=myisam;
 
497
create table t1 (a int, b varchar(200), c text not null);
 
498
create table t2 (a int, b varchar(200), c text not null);
499
499
insert t1 values (1, "aaa", "bbb"), (NULL, "", "ccccc"), (0, NULL, "");
500
500
insert t2 select * from t1;
501
501
--replace_column 1 #  6 # 7 # 8 # 9 # 10 #
531
531
#
532
532
# index search for NULL in blob. Bug #4816
533
533
#
534
 
create temporary table t1 ( a tinytext, b char(1), index idx (a(1),b) ) engine=myisam;
 
534
create table t1 ( a tinytext, b char(1), index idx (a(1),b) );
535
535
insert into t1 values (null,''), (null,'');
536
536
explain select count(*) from t1 where a is null;
537
537
select count(*) from t1 where a is null;
540
540
#
541
541
# bug9188 - Corruption Can't open file: 'table.MYI' (errno: 145)
542
542
#
543
 
create temporary table t1 (c1 int, c2 varchar(4) not null default '',
544
 
                 key(c2(3))) engine=myisam;
 
543
create table t1 (c1 int, c2 varchar(4) not null default '',
 
544
                 key(c2(3)));
545
545
insert into t1 values (1,'A'), (2, 'B'), (3, 'A');
546
546
update t1 set c2='A  B' where c1=2;
547
547
check table t1;
549
549
 
550
550
# BUG#13814 - key value packed incorrectly for TINYBLOBs
551
551
 
552
 
create temporary table t1(
 
552
create table t1(
553
553
  cip INT NOT NULL,
554
554
  score INT NOT NULL DEFAULT 0,
555
555
  bob TINYBLOB
556
 
) engine=myisam;
 
556
);
557
557
 
558
558
insert into t1 (cip) VALUES (1), (2), (3);
559
559
insert into t1 (cip, bob) VALUES (4, 'a' ), (5, 'b'), 
821
821
 
822
822
# BUG#9622 - ANALYZE TABLE and ALTER TABLE .. ENABLE INDEX produce
823
823
# different statistics on the same table with NULL values.
824
 
create temporary table t1 (a int, key(a)) engine=myisam;
 
824
create table t1 (a int, key(a));
825
825
 
826
826
insert into t1 values (1),(2),(3),(4),(NULL),(NULL),(NULL),(NULL);
827
827
analyze table t1;