MXS-1328 Mark regexp functions as builtin functions

Regexp functions were not listed among the builtin read-only
functions and consequently any SELECT using one of those was
routed to master.
This commit is contained in:
Johan Wikman 2017-07-27 09:46:34 +03:00
parent d54616f075
commit 4985bf9b6e
2 changed files with 12 additions and 0 deletions

View File

@ -360,6 +360,16 @@ static const char* BUILTIN_FUNCTIONS[] =
"to_base64",
"weight_string",
/*
* Regex functions
* https://mariadb.com/kb/en/mariadb/regular-expressions-functions/
*/
"regexp",
"regexp_instr",
"regexp_replace",
"regexp_substr",
"rlike",
/*
* http://dev.mysql.com/doc/refman/5.7/en/row-subqueries.html
*/

View File

@ -77,3 +77,5 @@ ROLLBACK TO SAVEPOINT id;
ROLLBACK WORK TO id;
ROLLBACK TO id;
RELEASE SAVEPOINT id;
SELECT her FROM (SELECT @@server_id as her) as t WHERE her REGEXP '.*';