Uploaded image for project: 'Xerces2-J'
  1. Xerces2-J
  2. XERCESJ-1609

Error: System ID:0Engine name: Xerces Severity: error Description: c-cta-xpath: The XPath expression 'matches(value,'^\d{4}$')' couldn't compile successfully in 'cta-subset' mode, during CTA evaluation. Start location: 26:108

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • 2.11.0
    • None
    • None
    • Oxygen 14.2, Linux Ubuntu 64 bit

    Description

      When using Oxygen I get an error reported, which is, in my opinion not an error. The (also in Oxygen included) Saxon-validation does not report an error. Oxygen uses:

      Name: org/apache/xerces/impl/Version.class
      Comment: Xerces-J 2.11.0-xml-schema-1.1-beta
      Implementation-Title: org.apache.xerces.impl.Version
      Implementation-Version: 2.11.0-xml-schema-1.1-beta
      Implementation-Vendor: Apache Software Foundation
      Implementation-URL: http://xerces.apache.org/xerces2-j/

      It is following example XSD which generates the error:

      <?xml version="1.0" encoding="UTF-8"?>
      <xs:schema xmlns:openkernel="http://rosa.openkernel/" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://rosa.openkernel/">
      <xs:element name="openEHR-DEMOGRAPHIC-PERSON.testdb_person.v1" type="openkernel:PERSONTYPE"/>
      <xs:complexType name="PERSONTYPE">
      <xs:sequence maxOccurs="1" minOccurs="1">
      <xs:element maxOccurs="1" minOccurs="1" name="openEHR-DEMOGRAPHIC-PERSON.testdb_person.v1">
      <xs:complexType>
      <xs:choice maxOccurs="unbounded" minOccurs="0">
      <xs:element name="at0001__details">
      <xs:complexType>
      <xs:sequence>
      <xs:choice maxOccurs="unbounded" minOccurs="0">
      <xs:element name="at0004__items">
      <xs:complexType>
      <xs:sequence>
      <xs:choice maxOccurs="unbounded" minOccurs="0">
      <xs:element name="at0005__items">
      <xs:complexType>
      <xs:sequence maxOccurs="1" minOccurs="1">
      <xs:element name="value">
      <xs:complexType>
      <xs:sequence maxOccurs="1" minOccurs="1">
      <xs:element name="value" type="xs:anyAtomicType">
      <xs:alternative test="matches(value,'^\d

      {4}-\d{2}-\d{2}$')" type="xs:date"/>
      <xs:alternative test="matches(value,'^\d{4}

      -\d

      {2}$')" type="xs:gYearMonth"/>
      <xs:alternative test="matches(value,'^\d{4}$')" type="xs:gYear"/>
      </xs:element>
      </xs:sequence>
      <xs:assert test="matches(value,'^\d{4}(-\d{2}

      (-\d

      {2})?)?$')" xpathDefaultNamespace="##targetNamespace"/>
      </xs:complexType>
      </xs:element>
      </xs:sequence>
      <xs:attribute fixed="at0005" name="archetype_node_id" use="required"/>
      </xs:complexType>
      </xs:element>
      </xs:choice>
      </xs:sequence>
      <xs:attribute fixed="at0004" name="archetype_node_id" use="required"/>
      </xs:complexType>
      </xs:element>
      </xs:choice>
      </xs:sequence>
      <xs:attribute fixed="at0001" name="archetype_node_id" use="required"/>
      </xs:complexType>
      </xs:element>
      </xs:choice>
      </xs:complexType>
      </xs:element>
      </xs:sequence>
      </xs:complexType>
      </xs:schema>

      The error messages are:
      System ID: bug18-3-2013.xsd
      Main validation file: bug18-3-2013.xml
      Schema: bug18-3-2013.xsd
      Engine name: Xerces
      Severity: error
      Description: c-cta-xpath: The XPath expression 'matches(value,'^\d{4}-\d{2}

      -\d

      {2}$')' couldn't compile successfully in 'cta-subset' mode, during CTA evaluation.
      Start location: 24:119

      System ID: bug18-3-2013.xsd
      Main validation file: bug18-3-2013.xml
      Schema: bug18-3-2013.xsd
      Engine name: Xerces
      Severity: error
      Description: c-cta-xpath: The XPath expression 'matches(value,'^\d{4}-\d{2}

      $')' couldn't compile successfully in 'cta-subset' mode, during CTA evaluation.
      Start location: 25:119

      System ID: bug18-3-2013.xsd
      Main validation file: bug18-3-2013.xml
      Schema: bug18-3-2013.xsd
      Engine name: Xerces
      Severity: error
      Description: c-cta-xpath: The XPath expression 'matches(value,'^\d

      {4}

      $')' couldn't compile successfully in 'cta-subset' mode, during CTA evaluation.
      Start location: 26:108

      Attachments

        Activity

          People

            Unassigned Unassigned
            verhees Bert Verhees
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: