diff options
author | Alexey Botchkov <holyfoot@askmonty.org> | 2020-06-04 13:53:14 +0400 |
---|---|---|
committer | Alexey Botchkov <holyfoot@askmonty.org> | 2020-06-04 13:53:14 +0400 |
commit | 74198384e140bfffb2cbf139ec02e4c91747fab8 (patch) | |
tree | 5bfa5130d7fefcee01c36a817b398d34bf49d68b /sql/item_jsonfunc.h | |
parent | 07daf735422403d2336df65ccc3f808d76b28497 (diff) | |
download | mariadb-git-74198384e140bfffb2cbf139ec02e4c91747fab8.tar.gz |
MDEV-21914 JSON_ARRAYAGG doesn't reject ORDER BY clause, but doesn't work either.
ORDER BY fixed for JSON_ARRAYAGG.
Diffstat (limited to 'sql/item_jsonfunc.h')
-rw-r--r-- | sql/item_jsonfunc.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sql/item_jsonfunc.h b/sql/item_jsonfunc.h index e5676768854..0b02b8e4da2 100644 --- a/sql/item_jsonfunc.h +++ b/sql/item_jsonfunc.h @@ -542,10 +542,13 @@ protected: Overrides Item_func_group_concat::skip_nulls() NULL-s should be added to the result as JSON null value. */ - virtual bool skip_nulls() const { return false; } + bool skip_nulls() const { return false; } + String *get_str_from_item(Item *i, String *tmp); + String *get_str_from_field(Item *i, Field *f, String *tmp, + const uchar *key, size_t offset); public: - String m_tmp_json; /* Used in convert_to_json. */ + String m_tmp_json; /* Used in get_str_from_*.. */ Item_func_json_arrayagg(THD *thd, Name_resolution_context *context_arg, bool is_distinct, List<Item> *is_select, const SQL_I_List<ORDER> &is_order, String *is_separator, @@ -560,7 +563,6 @@ public: const char *func_name() const { return "json_arrayagg("; } enum Sumfunctype sum_func() const {return JSON_ARRAYAGG_FUNC;} - String* convert_to_json(Item *item); String* val_str(String *str); Item *get_copy(THD *thd) |