Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> Re: selecting left x characters from a field?
select substr(stringvar, start, length)
if start is negative, it grabs characters from the end of the string: ie
substr(charval, -3 ) to get the last 3 characters
Medfly <medfly_at_iname.com> wrote in message
news:8plmte$scp$1_at_nnrp1.deja.com...
> Is there an equivalant LEFT or RIGHT function from VB that works in
> Oracle?
>
> Key
> ---
> 12345
>
> Is there a way to select the first 3 characters?
>
> SELECT LTRIM(Key,3) .... doesn't do the trick.
>
>
> thanks - medfly
>
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Tue Sep 12 2000 - 12:26:16 CDT