【发布时间】:2018-07-06 05:09:13
【问题描述】:
是否可以将JSON_EXTRACT 与整数键一起使用?
我想从下面提取[273, 140],但是SQL不起作用...
SELECT json_extract('{"1": [273, 140], "2": [273.5, 198.5], "3": [209, 191]}', '$.1');
我正在尝试使用来自 https://dev.mysql.com/doc/refman/5.7/en/json-search-functions.html#operator_json-column-path 的语法
我得到错误:
ERROR 3143 (42000): Invalid JSON path expression.
The error is around character position 3
【问题讨论】: