I want to delete the second element in the JSON array I inserted into test_details column.
How do I do this using DELETE SQL syntax?
CREATE TABLE test_json (
test_name VARCHAR2(1000) not null primary key,
test_details clob
CONSTRAINT test_valid_json CHECK (
test_details IS JSON
)
);
insert into test_json values('foo1', '["a","b"]');
SELECT test_name, value FROM test_json, json_table(test_json.test_details , '$[*]' COLUMNS (value PATH '$' ) );
Thanks,
Sandeep