Re: Forms 4.5 VALUE_ERROR. Help!
From: Steven P. Muench <smuench_at_oracle.com>
Date: 1995/07/18
Message-ID: <SMUENCH.95Jul17235758_at_doh.oracle.com>#1/1
Date: 1995/07/18
Message-ID: <SMUENCH.95Jul17235758_at_doh.oracle.com>#1/1
This is a simple, yet potentially baffling, problem. The behavior of the declarations:
local_var1 VARCHAR2;
local_var2 CHAR;
is effectively equivalent to:
local_var1 VARCHAR2(1);
local_var2 CHAR(1);
so, unless you had a one-character block name, your assignment statement is trying to force a string that longer than one character in a variable that's dimensioned to one character, hence the VALUE_ERROR exception.
The solution, is to explicitly dimension the string. For example:
local_var1 VARCHAR2(256); local_var2 CHAR(256);
Note that this is slightly confusing, since you are not allowed to dimension the string (or number) variables when declaring the datatypes of parameters to a program unit. PL/SQL handles the lengths of those automatically.
-- ___________________________________________________________ Steve Muench Email: smuench_at_us.oracle.com Sr. Product Manager Tools Development Oracle CorporationReceived on Tue Jul 18 1995 - 00:00:00 CEST