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

Home -> Community -> Usenet -> c.d.o.server -> help with regexp_substr using Oracle XE with Windows XP Home

help with regexp_substr using Oracle XE with Windows XP Home

From: <andrewbgilford_at_hotmail.co.uk>
Date: 24 Feb 2007 06:38:20 -0800
Message-ID: <1172327900.739151.130550@v33g2000cwv.googlegroups.com>

Hello - this is my first post to this professional newsgroup. If this is the wrong newsgroup please e-mail me and not flame me if I maked a mistake.

In Oracle what I want from my sql is the following results.

first second third fourth ------ ---------- -------------- --------- first second third word fourth.

What I have written is

SELECT REGEXP_SUBSTR('/first/second/third word/fourth./','/[a-z .]*/', 1,1) first,

       REGEXP_SUBSTR('/first/second/third word/fourth./','/[a-z .]*/', 1,2) second,

       REGEXP_SUBSTR('/first/second/third word/fourth./','/[a-z .]*/', 1,3) third,

       REGEXP_SUBSTR('/first/second/third word/fourth./','/[a-z .]*/', 1,4) fourth
  FROM DUAL but the occurrence value (the 1 or 2 or 3 or 4) in the manual from

http://download-west.oracle.com/docs/cd/B14117_01/server.101/b10759/functions116.htm

doesn't work properly. I think it does work but it is my sql that is wrong as I am a beginner. Can someone help me with the correct regexp_substr commands?

Thank you

Andy Received on Sat Feb 24 2007 - 08:38:20 CST

Original text of this message

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