MXS-1249: Add json functions

The json function are treated as read-only when the server version
is >= 10.2.3.
https://mariadb.com/kb/en/mariadb/json-functions/
This commit is contained in:
Johan Wikman
2017-06-19 18:16:44 +03:00
parent 4696c7e662
commit 43895b6f28
3 changed files with 76 additions and 10 deletions

View File

@ -1105,7 +1105,10 @@ static void update_field_infos(QC_SQLITE_INFO* info,
{
info->type_mask |= (QUERY_TYPE_READ | QUERY_TYPE_MASTER_READ);
}
else if (!is_builtin_readonly_function(zToken))
else if (!is_builtin_readonly_function(zToken,
this_thread.version_major,
this_thread.version_minor,
this_thread.version_patch))
{
info->type_mask |= QUERY_TYPE_WRITE;
}