mariadb/mysql-test/main/long_unique_bugs.result

56 lines
1.8 KiB
Text
Raw Normal View History

create table t1 (a int, b int, c int, d int, e int);
insert into t1 () values
(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),
(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),
(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),
(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),(),
(),(),(),();
select * into outfile 'load.data' from t1;
create temporary table tmp (a varchar(1024), b int, c int, d int, e linestring, unique (e));
load data infile 'load.data' into table tmp;
delete from tmp;
drop table t1;
create table t1 (b blob) engine=innodb;
alter table t1 add unique (b);
alter table t1 force;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`b` blob DEFAULT NULL,
UNIQUE KEY `b` (`b`) USING HASH
) ENGINE=InnoDB DEFAULT CHARSET=latin1
drop table t1;
create table t1 (pk int, b blob, primary key(pk), unique(b)) engine=myisam;
insert into t1 values (1,'foo');
replace into t1 (pk) values (1);
alter table t1 force;
replace into t1 (pk) values (1);
drop table t1;
create table t1 (t time, unique(t)) engine=innodb;
insert into t1 values (null),(null);
alter ignore table t1 modify t text not null default '';
Warnings:
Warning 1265 Data truncated for column 't' at row 1
Warning 1265 Data truncated for column 't' at row 2
drop table t1;
create table t1 ( pk int, f text, primary key (pk), unique(f)) with system versioning;
insert into t1 values (1,'foo');
update t1 set f = 'bar';
select * from t1;
pk f
1 bar
update t1 set f = 'foo';
select * from t1;
pk f
1 foo
select pk, f, row_end > DATE'2030-01-01' from t1 for system_time all;
pk f row_end > DATE'2030-01-01'
1 foo 1
1 foo 0
1 bar 0
drop table t1;
create temporary table t1 (f blob, unique(f)) engine=innodb;
insert into t1 values (1);
replace into t1 values (1);
drop table t1;