ORA-O1458 When Passing VARCHAR Host Variable as OUT Param of Stored Procedure (Doc ID 1010259.6)

Last updated on JULY 05, 2017

Applies to:

Precompilers - Version 9.2.0.8 and later
Information in this document applies to any platform.
***Checked for relevance on 26-Jul-2013***

Symptoms

Calling a PL/SQL stored procedure which has an OUT parameter from a Pro*C program.  The OUT parameter is of type VARCHAR or CHAR, and the host variable you are passing for this parameter is of type VARCHAR.

When you call the PL/SQL procedure, you receive the following error:

   ORA-01458 invalid length inside variable character string
 

For Example:

 

 
 
Sample Output:
 
Connected to ORACLE as user: SCOTT
Calling PL/SQL procedure myproc from C function proc1.
 
ORACLE error detected:
 
ORA-01458: invalid length inside variable character string

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