Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: pl help me in oracle

Re: pl help me in oracle

From: Robbert van der Hoorn <reply_at_forum.only>
Date: Thu, 28 Sep 2006 10:53:08 +0200
Message-ID: <451b8d80$0$4525$e4fe514c@news.xs4all.nl>

"saravanan" <saravanan120480_at_gmail.com> schreef in bericht news:1159429497.091295.160270_at_i42g2000cwa.googlegroups.com...
> hi,
> ls_line1 :=SUBSTR(trim(ls_line1),6,LENGTH(ls_line1));
> // this variable contains the value '126/1'
> ls_statement_no := SUBSTR(ls_line1, 1,INSTR(ls_line1,'/',1)- 1 ) ;
> // this variable contains the value '126'
> li_statement_no:=to_number(ls_statement_no);
>
> // it is working fine
>
> ls_page_no := SUBSTR(trim(ls_line1),
> INSTR(ls_line1,'/',1)+1,LENGTH(ls_line1));
> // this variable contains the value '1'
> li_page_no:=to_number(ls_page_no)
> when we convert the string to number , i got an error. the error is
> 06502- character to number conversion error
> even if i did the implicit conversion, it is throwing an error
>

Try to output the ls_page_no as varchar2 surrounded by another char (like *1*). You'll probably notice some extra trailing characters . Received on Thu Sep 28 2006 - 03:53:08 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US