json_array_contains()



Let us now check the json_array_contains(json_array text, value any) function with the following query.

Query

default> select json_array_contains('[10, 20, 30]', 10) as array_contains;  

Result

The above query will generate the following result.

array_contains 
------------------------------- 
true 

The query determines if the given value exists in the JSON array or not. Here, the given value 10 is present in the array so, the result is true.

apache_tajo_json_functions.htm
Advertisements