Tuesday, July 6, 2021

JSON Parsing

 DECLARE
v_response      CLOB := NULL;
 v_status              VARCHAR2 (2000);
   v_message             VARCHAR2 (2000);
BEGIN
v_response :='{"status":"NOK","message":"ZOOM: Meeting 99711037631 is not found or has expired."}';
apex_json.parse (p_source => v_response);
 v_status              := apex_json.get_varchar2('status');
   v_message             := apex_json.get_varchar2('message');
dbms_output.put_line('v_status='||v_status);
dbms_output.put_line('v_message='||v_message);
END;
/

v_status=NOK
v_message=ZOOM: Meeting 99711037631 is not found or has expired.

Statement processed.

0.01 seconds

No comments:

Post a Comment