Server IP : 185.86.78.101 / Your IP : 216.73.216.213 Web Server : Apache System : Linux 675867-vds-valikoshka1996.gmhost.pp.ua 5.4.0-150-generic #167-Ubuntu SMP Mon May 15 17:35:05 UTC 2023 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /www/server/mysql/mysql-test/r/ |
Upload File : |
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 explain extended select uncompress(compress(@test_compress_string)); id select_type table partitions type possible_keys key key_len ref rows filtered Extra 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL NULL No tables used Warnings: Warning 1681 'EXTENDED' is deprecated and will be removed in a future release. Note 1003 /* select#1 */ select uncompress(compress((@`test_compress_string`))) AS `uncompress(compress(@test_compress_string))` select uncompressed_length(compress(@test_compress_string))=length(@test_compress_string); uncompressed_length(compress(@test_compress_string))=length(@test_compress_string) 1 explain extended select uncompressed_length(compress(@test_compress_string))=length(@test_compress_string); id select_type table partitions type possible_keys key key_len ref rows filtered Extra 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL NULL No tables used Warnings: Warning 1681 'EXTENDED' is deprecated and will be removed in a future release. Note 1003 /* select#1 */ select (uncompressed_length(compress((@`test_compress_string`))) = length((@`test_compress_string`))) AS `uncompressed_length(compress(@test_compress_string))=length(@test_compress_string)` 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)) engine=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; select compress(""); compress("") select uncompress(""); uncompress("") select uncompress(compress("")); uncompress(compress("")) select uncompressed_length(""); uncompressed_length("") 0 create table t1 (a text); insert t1 values (compress(null)), ('A\0\0\0BBBBBBBB'), (compress(space(50000))), (space(50000)); select length(a) from t1; length(a) NULL 12 76 50000 select length(uncompress(a)) from t1; length(uncompress(a)) NULL NULL 50000 NULL Warnings: Warning 1259 ZLIB: Input data corrupted Warning 1256 Uncompressed data size too large; the maximum size is 4194304 (probably, length of uncompressed data was corrupted) drop table t1; set @@global.max_allowed_packet=1048576*100; select compress(repeat('aaaaaaaaaa', IF(XXX, 10, 10000000))) is null; compress(repeat('aaaaaaaaaa', IF(XXX, 10, 10000000))) is null 0 set @@global.max_allowed_packet=default; create table t1(a blob); insert into t1 values(NULL), (compress('a')); select uncompress(a), uncompressed_length(a) from t1; uncompress(a) uncompressed_length(a) NULL NULL a 1 drop table t1; create table t1(a blob); insert into t1 values ('0'), (NULL), ('0'); select compress(a), compress(a) from t1; select compress(a) is null from t1; compress(a) is null 0 1 0 drop table t1; End of 4.1 tests create table t1 (a varchar(32) not null); insert into t1 values ('foo'); explain select * from t1 where uncompress(a) is null; id select_type table partitions type possible_keys key key_len ref rows filtered Extra 1 SIMPLE t1 NULL system NULL NULL NULL NULL 1 100.00 NULL Warnings: Warning 1259 ZLIB: Input data corrupted Note 1003 /* select#1 */ select 'foo' AS `a` from dual where isnull(uncompress('foo')) select * from t1 where uncompress(a) is null; a foo Warnings: Warning 1259 ZLIB: Input data corrupted explain select *, uncompress(a) from t1; id select_type table partitions type possible_keys key key_len ref rows filtered Extra 1 SIMPLE t1 NULL system NULL NULL NULL NULL 1 100.00 NULL Warnings: Note 1003 /* select#1 */ select 'foo' AS `a`,uncompress('foo') AS `uncompress(a)` from dual select *, uncompress(a) from t1; a uncompress(a) foo NULL Warnings: Warning 1259 ZLIB: Input data corrupted select *, uncompress(a), uncompress(a) is null from t1; a uncompress(a) uncompress(a) is null foo NULL 1 Warnings: Warning 1259 ZLIB: Input data corrupted Warning 1259 ZLIB: Input data corrupted drop table t1; CREATE TABLE t1 (c1 INT); INSERT INTO t1 VALUES (1), (1111), (11111); SELECT UNCOMPRESS(c1), UNCOMPRESSED_LENGTH(c1) FROM t1; UNCOMPRESS(c1) UNCOMPRESSED_LENGTH(c1) NULL 0 NULL 0 NULL 825307441 EXPLAIN EXTENDED SELECT * FROM (SELECT UNCOMPRESSED_LENGTH(c1) FROM t1) AS s; DROP TABLE t1; End of 5.0 tests # # Bug#18693654 VALGRIND WARNINGS IN INFLATE ON UNCOMPRESS # SELECT UNCOMPRESS( CAST( 0 AS BINARY(5) ) ); UNCOMPRESS( CAST( 0 AS BINARY(5) ) ) NULL Warnings: Warning 1259 ZLIB: Input data corrupted