Unable to Call Oracle Stored Procedure ORA-06550 PLS-00306

Receiving Error when calling Oracle DB Stored Procedure.
Run Query: ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to ‘BULK_PRO_INS’
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
https://docs.oracle.com/error-help/db/ora-06550/

Stored PRocedure:
PROCEDURE BULK_PRO_INS(PI_PRO_DET IN CLOB,
PO_REF_CURSOR OUT SYS_REFCURSOR,
PO_MESS OUT VARCHAR2,
PO_ERROR_CODE OUT NUMBER,
PO_ERROR_MSG OUT VARCHAR2 );

Jboject(PI_PRO_DET as input parameter ):
CommandType:
StoredProcedure

SQL Query:“AR_PRVT.BULK_INS.BULK_PRO_INS”

First upgrade the UiPath.Database.Activities to 1.9.0 as starting with this version we solved this bug ‘Oracle store procedures with OracleRefCursor no longer throw exceptions.’

Reference: Activities - Release notes


The above error means that you’re calling the stored procedure with the wrong number or types of arguments. Specifically, you’re likely providing either too many, too few, or incorrectly typed arguments to the ‘BULK_PRO_INS’ procedure.

The procedure ‘BULK_PRO_INS’ requires five arguments:

  1. PI_PRO_DET: IN CLOB
  2. PO_REF_CURSOR: OUT SYS_REFCURSOR
  3. PO_MESS: OUT VARCHAR2
  4. PO_ERROR_CODE: OUT NUMBER
  5. PO_ERROR_MSG: OUT VARCHAR2

Make sure you’re providing all five arguments and that they are of correct types when you make the procedure call. Here is a sample call in PL/SQL might be:

DECLARE 
   PO_REF_CURSOR SYS_REFCURSOR;
   PO_MESS VARCHAR2(4000); 
   PO_ERROR_CODE NUMBER(10); 
   PO_ERROR_MSG VARCHAR2(4000);
BEGIN 
   your_schema.BULK_PRO_INS( 'your_clob_data', PO_REF_CURSOR, PO_MESS, PO_ERROR_CODE, PO_ERROR_MSG);
EXCEPTION 
   WHEN others THEN 
      dbms_output.put_line('Error code ' || sqlcode || ': ' || sqlerrm); 
END; 

Replace “your_schema”, “your_clob_data” with your actual schema and clob data.

Also, make sure the CLOB parameter you’re passing to the procedure is a valid CLOB object. You may need special handling to populate a CLOB value.

If you’re calling it from a code (like Java, C#, javascript etc.), you need to make sure you’re binding the arguments in the exact order and data types that the stored procedure expects.

Lastly, the stored procedure name should be called correctly. From your SQL query seems like you’re trying to call the procedure as “AR_PRVT.BULK_INS.BULK_PRO_INS”, please make sure the package name and procedure name is correct.