Test window - clob variable doesn't get passed to procedure

jure

Member²
When testing a procedure with clob parameter, the value of clob bind variable is not passed to the procedure.

Example:
- Create a procedure

SQL:
create or replace package pkg_clob is
  procedure print_clob(p_clob in clob);
end;
/
create or replace package body pkg_clob is
  procedure print_clob(p_clob in clob) is
  begin
    dbms_output.put_line(p_clob);
  end;
end;
/

- Test the procedure using test window

SQL:
begin
  -- Call the procedure
  pkg_clob.print_clob(p_clob => :p_clob);
end;

- Set a value for p_clob bind variable and run the test. Observe empty DBMS output.
 
Note that you need to declare the CLOB parameter as a "Temporary CLOB" instead of a "CLOB", which is a database CLOB. We'll make this the default to prevent this issue.
 
Back
Top