Home » Developer & Programmer » JDeveloper, Java & XML » how to use sql to bypass xml special character? Please....:)
icon4.gif  how to use sql to bypass xml special character? Please....:) [message #558259] Wed, 20 June 2012 07:51 Go to next message
Messages: 2
Registered: June 2012
Junior Member
"SELECT xmltype(RCATT).extract('/JASON/RCA/SUB_PROBLEM_TYPE').getStringVal() as SPT,
xmltype(RCATT).extract('/JASON/RCA/SUB_ROOT_CAUSE').getStringVal() as SRC,
xmltype(RCATTT).extract('/JASON/RCA/ELABORATION').getStringVal() as ELA,
xmltype(RCATT).extract('/JASON/RCA/PREVENTION').getStringVal() as PRE
FROM table"

ABove is my select starment

some explanation:
the above select statement is to select the child node inside the xml content.
But the child note contains some special character "<>" that illegally in xml.

Below is my xml content for the node of sub_problem_type

For <FS_PLS_WAIT>, it is appeared in both valid and invalid password entered case but in requirement, only valid case has stated the display of <FS_PLS_WAIT>. This is the legacy radio behavior.

The result will generate the following issue.

ORA-31011: XML parsing failed ORA-19202: Error occurred in XML processing LPX-00225: end-element tag "ELABORATION" does not match start-element tag "FS_PLS_WAIT" Error at line 10 ORA-06512: at "SYS.XMLTYPE", line 301 ORA-06512: at line 1

I wish to know where can i by pass the checking for special character
Re: how to use sql to bypass xml special character? Please....:) [message #558267 is a reply to message #558259] Wed, 20 June 2012 08:38 Go to previous message
Michel Cadot
Messages: 68418
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Waiting for your feedback in your previous topic...

Previous Topic: Select from XML
Next Topic: XML Parsing in PL/SQL without any DBMS_XML pacakges
Goto Forum:

Current Time: Sat Mar 25 00:41:22 CDT 2023