송찬호
02/06/2025, 7:44 AM[{"type": "baseball"}, {"type": "soccer"}]
For example,
SELECT
ARRAY(
MAKE_JSON_DATA('type', 'baseball'),
MAKE_JSON_DATA('type', 'soccer')
)Bolek Ziobrowski
02/06/2025, 9:58 AMcolumn), e.g.
select arrayIndexOfString( ARRAY('a', 'b', 'c'), 'c' ) from dual;
returns 2.
You could, in theory, create an array of JSON type but I believe it'd basically be an array of strings :
select array(cast( '{ "key": "value"}' as json )) as js_arrr from dual;송찬호
02/06/2025, 10:06 AMselect cast('{ "key": "value"}' as json) from dual works in a non-multi-stage environment but does not work in a multi-stage environment.
Additionally, the query select array(cast('{ "key": "value"}' as json)) as js_arr from dual; does not work either.
Could you provide more help?Bolek Ziobrowski
02/06/2025, 10:12 AMBolek Ziobrowski
02/06/2025, 10:24 AM송찬호
02/06/2025, 10:27 AMarrayToMv as mentioned in the documentation you provided.
I want to create array(json) when select SQL.