summaryrefslogtreecommitdiff
path: root/sql/sql_yacc.yy
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2022-06-02 07:48:30 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2022-06-02 07:48:30 +0300
commit712b443a3cef681ba3d6b103c2ebbd7a1862ef37 (patch)
tree8ac2164f3783b2b5c22520d77f3c1598a8d378fb /sql/sql_yacc.yy
parent52be05be15c679f2316c65ff7151f54f3957acef (diff)
parenta61603562e09f230e5ab6540b16e1c623520f9b2 (diff)
downloadmariadb-git-712b443a3cef681ba3d6b103c2ebbd7a1862ef37.tar.gz
Merge 10.6 into 10.7
Diffstat (limited to 'sql/sql_yacc.yy')
-rw-r--r--sql/sql_yacc.yy23
1 files changed, 22 insertions, 1 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 93a0163b073..eb1fee2a00c 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -1314,6 +1314,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, size_t *yystacksize);
TEXT_STRING
NCHAR_STRING
json_text_literal
+ json_text_literal_or_num
%type <lex_str_ptr>
opt_table_alias_clause
@@ -11292,6 +11293,26 @@ json_text_literal:
}
;
+json_text_literal_or_num:
+ json_text_literal
+ | NUM
+ {
+ Lex->json_table->m_text_literal_cs= NULL;
+ }
+ | LONG_NUM
+ {
+ Lex->json_table->m_text_literal_cs= NULL;
+ }
+ | DECIMAL_NUM
+ {
+ Lex->json_table->m_text_literal_cs= NULL;
+ }
+ | FLOAT_NUM
+ {
+ Lex->json_table->m_text_literal_cs= NULL;
+ }
+ ;
+
join_table_list:
derived_table_list { MYSQL_YYABORT_UNLESS($$=$1); }
;
@@ -11406,7 +11427,7 @@ json_on_response:
{
$$.m_response= Json_table_column::RESPONSE_NULL;
}
- | DEFAULT json_text_literal
+ | DEFAULT json_text_literal_or_num
{
$$.m_response= Json_table_column::RESPONSE_DEFAULT;
$$.m_default= $2;