JSON_DETAILED
Explore JSON_DETAILED in MariaDB. Also known as JSON_PRETTY, this function formats JSON documents with indentation and newlines to emphasize nested structures for readability.
Syntax
JSON_DETAILED(json_doc[, tab_size])
JSON_PRETTY(json_doc[, tab_size])Description
Example
SET @j = '{ "A":1,"B":[2,3]}';
SELECT @j;
+--------------------+
| @j |
+--------------------+
| { "A":1,"B":[2,3]} |
+--------------------+
SELECT JSON_DETAILED(@j);
+------------------------------------------------------------+
| JSON_DETAILED(@j) |
+------------------------------------------------------------+
| {
"A": 1,
"B":
[
2,
3
]
} |
+------------------------------------------------------------+See Also
Last updated
Was this helpful?

