diff options
author | unknown <gshchepa/uchum@host.loc> | 2008-02-13 19:32:19 +0400 |
---|---|---|
committer | unknown <gshchepa/uchum@host.loc> | 2008-02-13 19:32:19 +0400 |
commit | 247efb9cf060f0cd8d8eb7e4ecd084b9a202a395 (patch) | |
tree | b271e106f7200ee1759c75b179213ab22125297d /mysql-test/r | |
parent | b825be1bf81e68658ff39d1e6075489a84f4c8bf (diff) | |
download | mariadb-git-247efb9cf060f0cd8d8eb7e4ecd084b9a202a395.tar.gz |
Fixed bug#33764: Wrong result with IN(), CONCAT() and implicit
type conversion.
Instead of copying of whole character string from a temporary
buffer, the server copied a short-living pointer to that string
into a long-living structure. That has been fixed.
mysql-test/r/select.result:
Added test case for bug#33764.
mysql-test/t/select.test:
Added test case for bug#33764.
sql/item_cmpfunc.cc:
Fixed bug#33764.
Copying of a pointer has been replaced with an optional copying of
a whole array to a newly allocated memory space in case of a
functional source item.
Diffstat (limited to 'mysql-test/r')
-rw-r--r-- | mysql-test/r/select.result | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/mysql-test/r/select.result b/mysql-test/r/select.result index 3ca84bcf34b..180da5cd7d7 100644 --- a/mysql-test/r/select.result +++ b/mysql-test/r/select.result @@ -4328,4 +4328,10 @@ SELECT * FROM t1 WHERE c1 > NULL + 1; c1 DROP TABLE t1; +CREATE TABLE t1 (a VARCHAR(10) NOT NULL PRIMARY KEY); +INSERT INTO t1 (a) VALUES ('foo0'), ('bar0'), ('baz0'); +SELECT * FROM t1 WHERE a IN (CONCAT('foo', 0), 'bar'); +a +foo0 +DROP TABLE t1; End of 5.0 tests |