2000-12-28 02:56:38 +01:00
|
|
|
#
|
|
|
|
# Test of reading of bigint values
|
|
|
|
#
|
|
|
|
select 0,256,00000000000000065536,2147483647,-2147483648,2147483648,+4294967296;
|
|
|
|
select 9223372036854775807,-009223372036854775808;
|
|
|
|
select +9999999999999999999,-9999999999999999999;
|
|
|
|
|
|
|
|
drop table if exists t1;
|
2001-06-19 13:30:12 +02:00
|
|
|
create table t1 (a bigint unsigned not null, primary key(a));
|
|
|
|
insert into t1 values (18446744073709551615), (0xFFFFFFFFFFFFFFFE);
|
|
|
|
select * from t1;
|
|
|
|
select * from t1 where a=18446744073709551615;
|
|
|
|
select * from t1 where a='18446744073709551615';
|
|
|
|
delete from t1 where a=18446744073709551615;
|
2000-12-28 02:56:38 +01:00
|
|
|
select * from t1;
|
|
|
|
drop table t1;
|
2001-09-27 20:45:48 +02:00
|
|
|
|
|
|
|
create table t1 ( a int not null default 1, big bigint );
|
|
|
|
insert into t1 (big) values (-1),(12345678901234567),(9223372036854775807),(18446744073709551615);
|
|
|
|
select min(big),max(big),max(big)-1 from t1;
|
|
|
|
select min(big),max(big),max(big)-1 from t1 group by a;
|
|
|
|
alter table t1 modify big bigint unsigned not null;
|
|
|
|
select min(big),max(big),max(big)-1 from t1;
|
|
|
|
select min(big),max(big),max(big)-1 from t1 group by a;
|
|
|
|
alter table t1 add key (big);
|
|
|
|
select min(big),max(big),max(big)-1 from t1;
|
|
|
|
select min(big),max(big),max(big)-1 from t1 group by a;
|
|
|
|
alter table t1 modify big bigint not null;
|
|
|
|
select min(big),max(big),max(big)-1 from t1;
|
|
|
|
select min(big),max(big),max(big)-1 from t1 group by a;
|
|
|
|
drop table t1;
|
2002-01-02 20:29:41 +01:00
|
|
|
|
|
|
|
select UNSIGNED 1-2;
|
|
|
|
select SIGNED (UNSIGNED 1-2);
|
|
|
|
select UNSIGNED '-1';
|