OWA_PATTERN to remove any html
Date: Wed, 23 Apr 2003 09:25:26 +0200
Message-ID: <b85f6p$6gv4k$1_at_ID-138524.news.dfncis.de>
Hi all,
I'm trying to express a regular expression to remove any html in a given varchar2 variable. I've found the regular expression to do this in perl. It's:
$OnlyContent =~ s{<([^>])+>|&([^;])+;}{}gsx;
When I try to use this regular expression in PL/SQL I get the command:
L_source := '<html><body><b>test</b><a
href="http://www.test.com">something</a></body></html>';
L_count := OWA_PATTERN.CHANGE(L_source, '<([^>])+>|&([^;])+;', '', 'gi');
Every time I try to execute this, I get the following errors: ORA-06502: PL/SQL: numeric or value error: character to number conversion error
ORA-06512: at "SYS.OWA_PATTERN", line 444 ORA-06512: at "SYS.OWA_PATTERN", line 579 ORA-06512: at "SYS.OWA_PATTERN", line 1120
Could anybody tell me, what's wrong with the regular expression or how I could express a regular expression which removes any html in a given varchar2???
Thx!!
Best regards,
Ingo.
Received on Wed Apr 23 2003 - 09:25:26 CEST