ORABPEL-11811 and ORA-06502 when Executing a Stored Procedure from a BPEL Process (Doc ID 376950.1)

Last updated on NOVEMBER 03, 2016

Applies to:

Oracle(R) BPEL Process Manager - Version 10.1.2.0.2 to 10.1.3.5.0
Information in this document applies to any platform.
Checked for relevance on 02-MAY-2011


Symptoms

When attempting to invoke a stored procedure from within a BPEL process, an error similar to the following occurs.

<bindingFault>
...
Operation_ptt::Operation(InputParameters,OutputParameters) ] -WSIF JCA Execute of operation 'Operation' failed due to:
Error while trying to prepare and execute an API.
An error occurred while preparing and executing the APPS.* API.

Cause: java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error: character string buffer too small ORA-06512: at "APPS.*", line 5 ORA-06512: at line 1 ;
nested exception is:
ORABPEL-11811 Error while trying to prepare and execute an API. An error occurred while preparing and executing the APPS.* API. Cause: java.sql.SQLException:ORA-06502:
PL/SQL: numeric or value error: character string buffer too small ORA-06512: at "APPS.*", line 5 ORA-06512: at line 1
Check to ensure that the API is defined in the database and that the parameters match the signature of the API. Contact oracle support if error is not fixable.
...
ORA-06502: PL/SQL: numeric or value error: character string buffer too
small ORA-06512: at "APPS.*", line 5 ORA-06512: at line 1
...
</bindingFault>

The issue can be reproduced with the following steps:

    1. Create a simple stored procedure, for example:
PROCEDURE hello (input IN VARCHAR2, greeting OUT VARCHAR2) AS
str VARCHAR2(11);
BEGIN
str := 'Hello ' || input;
greeting := str;
END;

 

  1. Build a simple BPEL process to invoke this procedure. Please note that the length of the input parameter is less than or equal to 5.
  2. Deploy the process and test it given the input "World", and confirm that it executes successfully.
  3. Run the process given the input "World ", which contains a space character, and confirm that the error occurs.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms