• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Validating an XML fragment against a schema..

 
Ronan Dowd
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

Just wondering if there's a handy tool out there (on the web etc) that enables an XML fragment to be validated against a schema ?
I do realised I could write a SAX/DOM java class which would validate it one against the other but was wondering if there's a tool on
the web (maybe soapUI or something like it) that currently exists ?

Any help would be great.
Thanks, Ro
 
Kumar Raja
Ranch Hand
Posts: 547
2
Hibernate Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

XMLSpy is one of the tools which you can use. But I vaguely remember about an eclipse plugin which is freely available that can be used for this purpose. Recenly I used Oxygen XML for an evaluation period of 30 days and it is pretty cool.
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
While XMLSpy and Oxygen are excellent tools, all you need in this situation is Eclipse.
Make sure that you have specified the schema location in your XML document, then right-click on the XML document or in the editor of the XML document and select Validate.
It will validate your XML document against the XML schema.
Experiment with some illegal data in the XML document to see that validation fails.
Best wishes!
 
Dan Drillich
Ranch Hand
Posts: 1183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ronan,

There are web tools, such as XML Schema Validator or the official W3C Validator for XML Schema.

Regards,
Dan

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic