I need to extract some data from malformed XML stored in an Oracle database. The XPath expressions would look like this: //image/type/text()
. One take at a regular expression which would work in a similar fashion would be <image>.*?<type>(.+?)<\/type>
(with appropriate flags for multiline matching).
Since Oracle does not support match groups in any form for REGEXP_SUBSTR
I am unsure how to extract a set (with potentially n > 1 members) of match groups from an Oracle CLOB column. Any ideas?