Hi James,
Just from experience with regexes,
it might need to be "^\d{1,9}\.\d{2}$", specifying the start and end of the
string. Otherwise, if it finds the pattern at all, it will match (e.g.
1234567890.12 = 1(234567890.12), which is a match but not what you
expected).
Chris
-----Original Message-----
From: James Liu [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 21, 2002 8:16 AM
To: '[EMAIL PROTECTED]'
Subject: pattern in schemaHi,
I have the following definition in schema:
<xsd:simpleType name = "amount">
<xsd:restriction base = "xsd:string">
<xsd:pattern value = "\d{1,9}\.\d{2}"/>
</xsd:restriction>
</xsd:simpleType>
shouldn't 1234567890.12 be invalid value for this type? but Xerces 1.4.4 does not catch it. Anyone knows why?
thanks in advance,
James
