The jOOQ User Manual : SQL building : Conditional expressions : JSON_EXISTS predicate | previous : next |
JSON_EXISTS predicate
Applies to ✅ Open Source Edition ✅ Express Edition ✅ Professional Edition ✅ Enterprise Edition
The JSON_EXISTS
predicate can be used to check whether a JSON path expression produces a value within a JSON document (see also the JSON_VALUE function)
SELECT 1 FROM dual WHERE json_exists('{"a":1}', '$.a')
create.selectOne() .where(jsonExists(val(JSON.valueOf("{\"a\":1}")), "$.a")) .fetch();
Feedback
Do you have any feedback about this page? We'd love to hear it!