Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: LTRIM Function (URGENT)
If the two values are always delimited by spaces, and you
want the second value, then use the following:
update your_table
set documentno = substr(documentno, instr(documentno,' ',-1) +1 ) ;
This says: give me the section of documentno beginning with the first character after the last space in the string through the end of the string.
Test it with a query first to make sure it gives you what you want.
-Jay
"Tay, Virginia" wrote:
> Hi,
> I would like to trim the following field to be R-13935-01.....Is that a way
> that get rid of the first 32 characters (First 8 numbers + 24 spaces) by
> using LTRIM function....
>
> DOCUMENTNO
> ===========
> 00003331 R-13935-01
>
> Please help! THIS IS URGENT!
>
> Thanks a lot!
>
> Virginia
Received on Tue Jul 13 1999 - 10:08:38 CDT
![]() |
![]() |