• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

XML Validation against Schema

 
Ranch Hand
Posts: 122
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I am very much new web services. Currently, I am learning XML schema and try to validate an XML document with xsd. Should that be done programatically or does any of the editors provide a direct validation facility.

Having spoken about editors, I have currently installed XMLBuddy plug on to my eclipse 3.2. How should I proceed? Very much to eager to see my first xml validation happening against a schema...

Your help would really mean a lot!

Thanks
Srini
 
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Options are there in editors which would validate a XML with a given XSD.I use XML Spy ,it has this feature.

You can do this using java program as well , check the XMLFaq on javaranch for validation using program.
 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

In eclipse, just right click on the xml and click on validate, if your instance document (XML) has the schema declaration, it validates with the corresponding schema and shows errors(if any) in the editor itself.

It can be done using programatically also.. which option to choose depends on your requirement.

-Katta
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic