Help need using
Date: Thu, 22 Aug 2019 16:16:10 -0300
Message-ID: <CAPWdmV8007Vm1bSX5wDbenEbHQjz4pN03LLhG7Na4NC5poaW4A_at_mail.gmail.com>
Hello list!
First forgive me for not digging into documentation, but I'm not a regular expression expert.
I need to perform a simple string parse, to get parameters separeted by white space (or tabs) with unknown count.
I reached to this:
>
>
>
>
>
>
>
> *SQL> select regexp_substr ('Param1 Param2 Param3','[[:graph:]]+', 1,
> rownum) Parameter 2 from dual 3 connect by level <= 3 4
> /PARAMETER--------------------------------------------------------------------------------Param1Param2Param3*
But I need to consider, in special case, a group of words, enclosed with double quotes, as a single parameter.
But, of course, this will not work:
> *SQL> select regexp_substr ('Param1 "Param2 Param3"','[[:graph:]]+', 1,
> rownum) Parameter*
> * 2 from dual*
> * 3 connect by level <= 3** 4 /*
>
> *PARAMETER*
>
> *----------------------------------------------------------------------------------------*
> *Param1*
> *"Param2**Param3"*
How can I get the following output:
> *PARAMETER*
>
> *----------------------------------------------------------------------------------------*
> *Param1**"Param2 Param3"*
Best regards,
Luis Santos
--http://www.freelists.org/webpage/oracle-l Received on Thu Aug 22 2019 - 21:16:10 CEST