diff options
author | unknown <ramil/ram@mysql.com/myoffice.izhnet.ru> | 2006-10-13 19:05:54 +0500 |
---|---|---|
committer | unknown <ramil/ram@mysql.com/myoffice.izhnet.ru> | 2006-10-13 19:05:54 +0500 |
commit | 60a21d16975de436d57c9e29f237234b71fd5601 (patch) | |
tree | 0170e1ae102bd9bae909c42003f5bb013fb6b058 /mysql-test/r/func_compress.result | |
parent | e203f0e578a064bee54d600b2c70424b9f9c9365 (diff) | |
download | mariadb-git-60a21d16975de436d57c9e29f237234b71fd5601.tar.gz |
Fix for bug #23254: COMPRESS(NULL) makes all futher COMPRESS() calls on same Item return NULL
We don't set null_value to 0 in the Item_func_compress::val_str() for
not-NULL results.
mysql-test/r/func_compress.result:
Fix for bug #23254: COMPRESS(NULL) makes all futher COMPRESS() calls on same Item return NULL
- test result.
mysql-test/t/func_compress.test:
Fix for bug #23254: COMPRESS(NULL) makes all futher COMPRESS() calls on same Item return NULL
- test case.
sql/item_strfunc.cc:
Fix for bug #23254: COMPRESS(NULL) makes all futher COMPRESS() calls on same Item return NULL
- set null_value.
Diffstat (limited to 'mysql-test/r/func_compress.result')
-rw-r--r-- | mysql-test/r/func_compress.result | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/mysql-test/r/func_compress.result b/mysql-test/r/func_compress.result index 8d6fa9927ce..ed8d66e9327 100644 --- a/mysql-test/r/func_compress.result +++ b/mysql-test/r/func_compress.result @@ -79,3 +79,13 @@ 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 |