Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: ORA-06502 when using to_char function
what does your format model look like?
<mfugazi_at_my-deja.com> wrote in message news:8kvpma$cet$1_at_nnrp2.deja.com...
> I have a stored procedure in Oracle with a
> varchar2 out parameter.
>
> CREATE OR REPLACE procedure
> a_proc ( a_string out varchar2 )
>
> In the body of the stored proc I've declared a
> variable v_num number(9,3) which is initialized
> by a select statement
>
> select some_col into v_num from some_table;
>
> Now, I want to convert v_num into a string and
> assigned it to the out parameter.
>
> select to_char(v_num,') into a_string from dual;
>
> The stored proc is valid when I compile it, but I
> get this error when I run it:
>
> ORA-06502, "PL/SQL: numeric or value error"
>
>
> Can someone tell me what I'm doing wrong ?
>
> Thanks.
>
>
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Mon Jul 17 2000 - 00:00:00 CDT
![]() |
![]() |