0 Replies Latest reply on Jan 30, 2013 7:56 AM by user564736

    XML validation using Oracle XML parser v2

      Not sure if this is the right forum for this question as I didn't found any.

      I had a tough time trying to build an XMLSchema (Oracle XML Parser V2) object from the input schema having include/import. Actually I am working on a Java program to validate the input xml with input schema using Oracle XML parser v2 api.

      The issue is that the code doesn't work for schema that has some "include" in it. The code is working fine for the schema without any import/include. Here is the lines of code -

      XSDBuilder builder = new XSDBuilder();

      schema = builder.build(new InputSource(xsdReader));
      I am writing this in JDeveloper. The error is -

      oracle.xml.parser.schema.XSDException: Can not build schema 'http://www.fpml.org/2005/FpML-4-2' located at 'xsd\FpML42\xml\fpml-fx-4-2.xsd'

      I also tried creating the EntityResolver to specify the path of included schema. But that doesn't solves the problem.

      I am not sure whether parser is able to locate the included schema or not.The main schema and included schema are all in same folder. The included schema is perfectly fine and has no errors.

      Please help if you have encountered this issue and resolved it. I will really appreciate any pointers or clue to solve this issue.