[ 
https://issues.apache.org/jira/browse/XERCESJ-955?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12544797
 ] 

Dave Hoffer commented on XERCESJ-955:
-------------------------------------

Yes, I too have schemas defined with this problem.  What is the fix/workaround? 
 How can I change the schema to that xerces can handle the same functionality?

> InvalidRegex for correct regular expression
> -------------------------------------------
>
>                 Key: XERCESJ-955
>                 URL: https://issues.apache.org/jira/browse/XERCESJ-955
>             Project: Xerces2-J
>          Issue Type: Bug
>          Components: XML Schema API
>    Affects Versions: 2.5.0
>         Environment: Windows 2000, java version "1.4.1_02"
>            Reporter: Dietrich Vatter
>            Priority: Minor
>
> running org.xml.sax.XMLReader with this java code
> reader = XMLReaderFactory.createXMLReader();
> reader.setFeature("http://apache.org/xml/features/validation/schema";, true);
> reader.setFeature("http://xml.org/sax/features/validation";, true);
> against this schema extract (original taken from www.bmecat.org)
> <xsd:simpleType name="dtTIMEZONETYPE">
> <xsd:restriction base="xsd:string">
> <xsd:pattern value="([+-]([0-1][0-9]|2[0-3])(:[0-5][0-9]))|Z"/>
> </xsd:restriction>
> </xsd:simpleType>
> in this error:
> [Error] bmecat_new_catalog_1_2.xsd:2952:38: InvalidRegex: Pattern value 
> '([+-]([0-1][0-9]|2[0-3])(:[0-5][0-9]))|Z' is not a valid regular expression. 
> The reported error was: ''-' is an invalid character range. Write '\-'.'.
> Looks like it assumes a range when hitting the '-', but it is actually just a 
> character. Probably needs to check whether '-' is at beginning or and of 
> brackets.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to