Validating XML document without using "xsi:schemaLocation" attribute

Discussion in 'XML' started by Naresh Agarwal, Jan 13, 2004.

  1. Hi

    I'm using SAX Parser of Xerces Java v2.4.0 for XML Parsing.
    I want to perform schema validations on the xml.

    The problem is that root element of XML document does not have
    "xsi:schemaLocation" attribute, which is used to specify the .xsd
    file.

    Is there any other way for specifying the name of .xsd file?

    thanks,
    Naresh
     
    Naresh Agarwal, Jan 13, 2004
    #1
    1. Advertising

  2. Hello,

    > Hi
    >
    > I'm using SAX Parser of Xerces Java v2.4.0 for XML Parsing.
    > I want to perform schema validations on the xml.
    >
    > The problem is that root element of XML document does not have
    > "xsi:schemaLocation" attribute, which is used to specify the .xsd
    > file.
    >
    > Is there any other way for specifying the name of .xsd file?


    Take a look at
    http://java.sun.com/webservices/docs/1.3/tutorial/doc/JAXPSAX9.html#wp65302

    There is a paragraph "You can also specify the schema file in the
    application, using code like this:"

    I hope this helps.

    Bye
    C. Ludwig
     
    Christian Ludwig, Jan 13, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Tony Prichard
    Replies:
    0
    Views:
    772
    Tony Prichard
    Dec 12, 2003
  2. Sarah Tegtmeier

    correct use of xsi:schemaLocation

    Sarah Tegtmeier, Jan 16, 2004, in forum: XML
    Replies:
    0
    Views:
    940
    Sarah Tegtmeier
    Jan 16, 2004
  3. Kevin Partin
    Replies:
    1
    Views:
    1,421
    Martin Honnen
    Feb 13, 2004
  4. Xavier Seneque
    Replies:
    0
    Views:
    630
    Xavier Seneque
    Jul 9, 2005
  5. Replies:
    0
    Views:
    576
Loading...

Share This Page