summaryrefslogtreecommitdiff
path: root/mysql-test/r/func_regexp.result
diff options
context:
space:
mode:
authorRamil Kalimullin <ramil@mysql.com>2008-08-15 10:53:25 +0500
committerRamil Kalimullin <ramil@mysql.com>2008-08-15 10:53:25 +0500
commitfb79a269c488060614e5b0ac96636d74f0046b6e (patch)
treea08c236e1dd1f862929a2cacef67cf7afea5827d /mysql-test/r/func_regexp.result
parent494c0e6d7ce7a54ed93070caa792484d856754ec (diff)
downloadmariadb-git-fb79a269c488060614e5b0ac96636d74f0046b6e.tar.gz
Fix for bug#37337: Function returns different results
Problem: REGEXP in functions/PSs may return wrong results due to improper initialization. Fix: initialize required REGEXP params.
Diffstat (limited to 'mysql-test/r/func_regexp.result')
-rw-r--r--mysql-test/r/func_regexp.result18
1 files changed, 18 insertions, 0 deletions
diff --git a/mysql-test/r/func_regexp.result b/mysql-test/r/func_regexp.result
index 794ae79973a..b64f0b7f1c1 100644
--- a/mysql-test/r/func_regexp.result
+++ b/mysql-test/r/func_regexp.result
@@ -115,3 +115,21 @@ SELECT 1 REGEXP NULL;
1 REGEXP NULL
NULL
End of 5.0 tests
+CREATE TABLE t1(a INT, b CHAR(4));
+INSERT INTO t1 VALUES (1, '6.1'), (1, '7.0'), (1, '8.0');
+PREPARE stmt1 FROM "SELECT a FROM t1 WHERE a=1 AND '7.0' REGEXP b LIMIT 1";
+EXECUTE stmt1;
+a
+1
+EXECUTE stmt1;
+a
+1
+EXECUTE stmt1;
+a
+1
+EXECUTE stmt1;
+a
+1
+DEALLOCATE PREPARE stmt1;
+DROP TABLE t1;
+End of 5.1 tests