Below code work in oracle 11g but oracle 12c release 1 give ora-00600 error. How can I make it database version independence?
DECLARE
lxml xmltype;
l_tag varchar2(30);
begin
lxml :=
xmltype('<responseObject>
<error>That is not a valid request</error>
<errorCode>A11</errorCode>
<value>A</value>
</responseObject>
');
l_tag := 'responseObject/*';
FOR test IN (
select tag,
VALUE
FROM xmltable(l_tag
passing lxml
columns
tag VARCHAR2(128) path 'name()',
VALUE VARCHAR2(128) path '.'
) t
)
LOOP
dbms_output.put_line(test.tag || ' - ' || test.value);
END LOOP;
end;
/
This issue is fixed in patch 26281022 which is due to bug 25437089 and 25967544. More details are available in this link
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.