Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

[APEX5.0]PL/SQL CLOB Sampling error

Arthur R.Dec 11 2017 — edited Dec 11 2017

Hello,

ISSUE

I'm trying to write many lines in the HTML of my plugin. In order to do so I stocked all my HTML lines in a very long CLOB called "JScript". I use htp.prn to write JScript in my HTML. Since htp.prn can't all JScript lines I sample JScript into substrings that I give to htp.prn. Unfortunatly  the code I wrote give me back errors.

CODE

jsonString CLOB;

x int;

i int :=1;

...

  x:=ROUND(JScript.length/32767);

  FOR i IN 0..x LOOP

      htp.prn(DBMS_LOB.SUBSTR(JScript, 32767, i*32767+1));

  END LOOP;

  IF JScript.length>x*32767 THEN

      htp.prn(DBMS_LOB.SUBSTR(JScript, JScript.length-x*32767, x*32767+1));

  END IF;

ERROR

ORA-06550: line 613, column 20: PLS-00487: Invalid reference to variable 'JSCRIPT' ORA-06550: line 613, column 3: PL/SQL: Statement ignored ORA-06550: line 617, column 14: PLS-00487: Invalid reference to variable 'JSCRIPT' ORA-06550: line 617, column 3: PL/SQL: Statement ignored

Any help is appreciated.

Thank you for reading.

This post has been answered by Arthur R. on Dec 11 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 8 2018
Added on Dec 11 2017
2 comments
111 views