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: return first token/word from string?

Re: return first token/word from string?

From: Brian Peasland <dba_at_nospam.peasland.net>
Date: Wed, 22 Aug 2007 14:44:29 -0500
Message-ID: <46cc861f$0$26114$88260bb3@free.teranews.com>


jobs wrote:

> On Aug 22, 3:31 pm, DA Morgan <damor..._at_psoug.org> wrote:
>> jobs wrote:

>>> I'm on Oracle 9i. Is there any built in function that would return the
>>> first token or string from a string?
>>> For example, given string = " bob lfcr bill"
>>> I want to return "bob"
>>> imediately following bob there might be cases where we have a linefeed/
>>> cr.
>>> Thanks for any help or information.
>> Look at REGEXP_SUBSTRhttp://www.psoug.org/reference/regexp.html#rerp
>> --
>> Daniel A. Morgan
>> University of Washington
>> damor..._at_x.washington.edu (replace x with u to respond)
>> Puget Sound Oracle Users Groupwww.psoug.org
> 
> Is that supported in 9i? I can't seem to get it to work here.
> 

It is not supported in 9i. Regular Expression functions first appear in 10g.

Most likely in 9i, you'll have to build your own functions using the INSTR and SUBSTR functions.

HTH,
Brian

-- 
===================================================================

Brian Peasland
dba_at_nospam.peasland.net
http://www.peasland.net

Remove the "nospam." from the email address to email me.


"I can give it to you cheap, quick, and good.
Now pick two out of the three" - Unknown

-- 
Posted via a free Usenet account from http://www.teranews.com
Received on Wed Aug 22 2007 - 14:44:29 CDT

Original text of this message

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