diff options
author | Alexander Barkov <bar@mnogosearch.org> | 2014-04-21 13:19:32 +0400 |
---|---|---|
committer | Alexander Barkov <bar@mnogosearch.org> | 2014-04-21 13:19:32 +0400 |
commit | 213f10363e1134fdb39842f55876db1136496ff3 (patch) | |
tree | c4e90fef04a14840f730a7e2e42863349b123943 /mysql-test/t | |
parent | 5fc5195fc5e5adfcbf63dd1297495e77399e2a32 (diff) | |
download | mariadb-git-213f10363e1134fdb39842f55876db1136496ff3.tar.gz |
MDEV-6045 MySQL Bug#11829861 - SUBSTRING_INDEX() RESULTS "OMIT" CHARACTER WHEN USED INSIDE LOWER()
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/func_str.test | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/mysql-test/t/func_str.test b/mysql-test/t/func_str.test index 661cc6896c0..c52b284078f 100644 --- a/mysql-test/t/func_str.test +++ b/mysql-test/t/func_str.test @@ -1405,3 +1405,30 @@ select group_concat( i ), make_set( i, 'a', 'b' ) field from t1 group by field; drop table t1; --echo End of 5.1 tests + +--echo # +--echo # Start of 5.3 tests +--echo # + +--echo # +--echo # Bug#11829861: SUBSTRING_INDEX() RESULTS IN MISSING CHARACTERS WHEN USED +--echo # INSIDE LOWER() +--echo # +SET @user_at_host = 'root@mytinyhost-PC.local'; +SELECT LOWER(SUBSTRING_INDEX(@user_at_host, '@', -1)); +--echo # End of test BUG#11829861 + +--echo # +--echo # Bug#42404: SUBSTRING_INDEX() RESULTS ARE INCONSISTENT +--echo # + +CREATE TABLE t (i INT NOT NULL, c CHAR(255) NOT NULL); +INSERT INTO t VALUES (0,'.www.mysql.com'),(1,'.wwwmysqlcom'); +SELECT i, SUBSTRING_INDEX(c, '.', -2) FROM t WHERE i = 1; +SELECT i, SUBSTRING_INDEX(c, '.', -2) FROM t; +DROP TABLE t; +--echo # End of test BUG#42404 + +--echo # +--echo # End of 5.3 tests +--echo # |