| Article: |
XML Document Validation with an XML Schema | |
| Subject: | Error coming | |
| Date: | 2007-01-09 15:08:32 | |
| From: | javanew | |
|
Response to: Error coming
|
||
|
i was not specifying noNamespaceSchemaLocation attribute. My xml looked like this: <?xml version="1.0" encoding="utf-8" ?> <catalog xmlns="catalog.xsd"> <journal date="April 2004"> <article> <title>Declarative Programming in Java</title> <author>Narayanan Jayaratchagan</author> </article> </journal> <journal date="January 2004"> <article> <title>Data Binding with XMLBeans</title> <author>Daniel Steinberg</author> </article> </journal> </catalog> |
||
Showing messages 1 through 3 of 3.
-
Error coming
2007-01-09 15:13:51 Deepak Vohra | [Reply | View]
-
Error coming
2007-01-09 15:13:04 Deepak Vohra | [Reply | View]
Please modify the root element.
<catalog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file://c:/Schemas/OracleCatalog.xsd"> -
Error coming
2007-01-09 15:26:03 javanew [Reply | View]
Both xml and xsd are WSAD workspace, so I cannot give file path. There are in the same location. So, is there any way I can specify the path?
<?xml version="1.0" encoding="utf-8" ?>
<catalog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="catalog.xsd" >
<journal date="April 2004">
<article>
<title>Declarative Programming in Java</title>
<author>Narayanan Jayaratchagan</author>
</article>
</journal>
<journal date="January 2004">
<article>
<title>Data Binding with XMLBeans</title>
<author>Daniel Steinberg</author>
</article>
</journal>
</catalog>




<catalog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file://c:/Schemas/catalog.xsd">