Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

DTD + Schema reference in xml file to be inserted

User11853430-OracleNov 25 2010 — edited Dec 1 2010
Hi,

I am pasting sample code where I want to have schema + DTD reference. Schema file is used for validating the file and DTD is needed for entity resolution.
<?xml version="1.0" ?>
<!DOCTYPE html [
<!ENTITY reg    "®">
]>
<html xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.xsd">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
</head>

<!-- class="header" -->
<body>
Hi all. Register symbol should be displayed now &reg;
</body>
</html>
I have already registered http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.xsd schema with the DB. But, when I try to insert this xml data in the DB, I'm getting the following error.
SQL Error: ORA-31011: XML parsing failed
ORA-19202: Error occurred in XML processing
LPX-00104: Warning: element "html" is not declared in the DTD
Error at line 5
ORA-06512: at "SYS.XMLTYPE", line 296
ORA-06512: at line 1
31011. 00000 -  "XML parsing failed"
*Cause:    XML parser returned an error while trying to parse the document.
*Action:   Check if the document to be parsed is valid.
Anyone please help me in resolving this issue..

Thanks in advance,
Divya.

Edited by: user11853430 on Nov 28, 2010 8:45 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 29 2010
Added on Nov 25 2010
9 comments
1,130 views