Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: how to retrieve numeric values only from a varchar2?
Just when I think I'm cought up on the Oracle-installed PL/SQL packages...
Seeing as OWA_PATTERN isn't in the docs (not on tahiti, anyway), is it supported???
Rich
Rich Jesse System/Database Administrator Rich.Jesse_at_qtiworld.com Quad/Tech International, Sussex, WI USA
> -----Original Message-----
> From: Jared.Still_at_radisys.com [mailto:Jared.Still_at_radisys.com]
> Sent: Monday, October 07, 2002 1:58 PM
> To: Multiple recipients of list ORACLE-L
> Subject: Re: how to retrieve numeric values only from a varchar2?
>
>
> Use owa_pattern.
>
> See $ORACLE_HOME/rdbms/admin/pubpat.sql
>
> Here's an example:
>
> declare
> tstr varchar2(100) := 'this string has 382 embedded numeric data';
> begin
> dbms_output.put_line( tstr);
> -- remove the digits
> owa_pattern.change( tstr, '\D', '', 'g');
> dbms_output.put_line( tstr);
> end;
> /
>
> Jared
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Jesse, Rich INET: Rich.Jesse_at_qtiworld.com Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Mon Oct 07 2002 - 14:39:02 CDT
![]() |
![]() |