diff options
author | unknown <sasha@asksasha.com> | 2006-01-30 20:35:33 -0700 |
---|---|---|
committer | unknown <sasha@asksasha.com> | 2006-01-30 20:35:33 -0700 |
commit | 4f9088ae858b2e19d5ac1989d1521bcbc1809f07 (patch) | |
tree | a7caf4d5923cde8631696a845b2da290cd19ccfa /mysql-test/t/mysqltest.test | |
parent | d5850475d1711ebb2883b6697e9ad188a1df8cbf (diff) | |
download | mariadb-git-4f9088ae858b2e19d5ac1989d1521bcbc1809f07.tar.gz |
#WL3026 - replace_regex in mysqltest
Diffstat (limited to 'mysql-test/t/mysqltest.test')
-rw-r--r-- | mysql-test/t/mysqltest.test | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/mysql-test/t/mysqltest.test b/mysql-test/t/mysqltest.test index 440a7787985..cfa2599e384 100644 --- a/mysql-test/t/mysqltest.test +++ b/mysql-test/t/mysqltest.test @@ -994,4 +994,30 @@ drop table t1; drop table t1; +# test for replace_regex +--replace_regex /at/b/ +select "at" as col1, "c" as col2; +--replace_regex /at/b/i +select "at" as col1, "AT" as col2, "c" as col3; + +--replace_regex /a/b/ /ct/d/ +select "a" as col1, "ct" as col2; + +--replace_regex /(strawberry)/raspberry and \1/ /blueberry/blackberry/ /potato/tomato/; +select "strawberry","blueberry","potato"; + +--error 1 +--exec echo "--replace_regex a" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "--replace_regex a;" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "replace_regex a;" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "replace_regex a ;" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "replace_regex a b; echo OK;" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "--replace_regex /a b c" | $MYSQL_TEST 2>&1 +--error 1 +--exec echo "replace_regex /a /b c ;" | $MYSQL_TEST 2>&1 |