-> FROM -> JSON_TABLE( -> ’[{"x":2,"y":"8"},{"x":"3","y":"7"},{"x":"4","y":6}]’, -> "$[*]" COLUMNS( -> xval VARCHAR(100) PATH "$.x", -> yval VARCHAR(100) PATH "$.y" -> ) -> ) AS jt1; +------+------+ | xval | yval | +------+------+ | 2 | 8 | | 3 | 7 | | 4 | 6 | +------+------+ 

The expression "$[*]"  matches each element of the array. You can filter the rows in the result by modifying the path. For example, using "$[1]"  limits extraction to the second element of the JSON array used as the source, as shown here: 

mysql> SELECT * -> FROM -> JSON_TABLE( -> ’[{"x":2,"y":"8"},{"x":"3","y":"7"},{"x":"4","y":6}]’, -> "$[1]" COLUMNS( -> xval VARCHAR(100) PATH "$.x", -> yval VARCHAR(100) PATH "$.y" -> ) -> ) AS jt1; +------+------+ | xval | yval | +------+------+ | 3 | 7 | +------+------+ 

Within a column definition, "$"  passes the entire match to the column; "$.x"  and "$.y"  pass only the values corresponding to the keys x  and y , respectively, within that match. For more information, see JSON Path Syntax. 

NESTED PATH  (or simply NESTED ; PATH  is optional) produces a set of records for each match in the COLUMNS  clause to which it belongs. If there is no match, all columns of the nested path are set to NULL . This implements an outer join between the topmost clause and NESTED [PATH] . An inner join can be emulated by applying a suitable condition in the WHERE  clause, as shown here: 

mysql> SELECT * -> FROM -> JSON_TABLE( -> ’[ {"a": 1, "b": [11,111]}, {"a": 2, "b": [22,222]}, {"a":3}]’, -> ’$[*]’ COLUMNS( -> a INT PATH ’$.a’, -> NESTED PATH ’$.b[*]’ COLUMNS (b INT PATH ’$’) -> ) -> ) AS jt -> WHERE b IS NOT NULL; +------+------+ | a | b | +------+------+ | 1 | 11 | | 1 | 111 | | 2 | 22 | | 2 | 222 | 

