2003-04-10 02:50:30 +02:00
|
|
|
select @test_compress_string:='string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa ';
|
|
|
|
@test_compress_string:='string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa '
|
|
|
|
string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
|
|
|
select length(@test_compress_string);
|
|
|
|
length(@test_compress_string)
|
|
|
|
117
|
|
|
|
select uncompress(compress(@test_compress_string));
|
|
|
|
uncompress(compress(@test_compress_string))
|
|
|
|
string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
|
|
|
select uncompressed_length(compress(@test_compress_string))=length(@test_compress_string);
|
|
|
|
uncompressed_length(compress(@test_compress_string))=length(@test_compress_string)
|
|
|
|
1
|
|
|
|
select uncompressed_length(compress(@test_compress_string));
|
|
|
|
uncompressed_length(compress(@test_compress_string))
|
|
|
|
117
|
|
|
|
select length(compress(@test_compress_string))<length(@test_compress_string);
|
|
|
|
length(compress(@test_compress_string))<length(@test_compress_string)
|
|
|
|
1
|
|
|
|
create table t1 (a text, b char(255), c char(4)) type=myisam;
|
|
|
|
insert into t1 (a,b,c) values (compress(@test_compress_string),compress(@test_compress_string),'d ');
|
|
|
|
select uncompress(a) from t1;
|
|
|
|
uncompress(a)
|
|
|
|
string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
|
|
|
select uncompress(b) from t1;
|
|
|
|
uncompress(b)
|
|
|
|
string for test compress function aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
|
|
|
select concat('|',c,'|') from t1;
|
|
|
|
concat('|',c,'|')
|
|
|
|
|d|
|
|
|
|
drop table t1;
|
2003-04-23 00:41:47 +02:00
|
|
|
select compress("");
|
|
|
|
compress("")
|
|
|
|
|
|
|
|
select uncompress("");
|
|
|
|
uncompress("")
|
|
|
|
|
|
|
|
select uncompress(compress(""));
|
|
|
|
uncompress(compress(""))
|
|
|
|
|
|
|
|
select uncompressed_length("");
|
|
|
|
uncompressed_length("")
|
|
|
|
0
|