![]() |
![]() | ![]() | ![]() | Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries >Thread Prev - Need help with xsd pattern [Thread Next] Re: Need help with xsd patternTo: NULL Date: 3/3/2005 3:41:00 PM Have you tried validating your schema using engines other than XMLSpy">XMLSpy? Try the following: http://apps.gotdotnet.com/xmltools/xsdvalidator/ http://www.w3.org/2001/03/webdata/xsv -- Stan Kitsis Program Manager, XML Technologies Microsoft Corporation This posting is provided "AS IS" with no warranties, and confers no rights. "Rasmus" <Rasmus@n...> wrote in message news:0EEAD4E0-6248-4F5D-93A0-6D2E10C259E5@m...... >I need to restrict an element attibutes value to only contain characters >a-z > and the underscore character. - the validation should be case insensitive. > > This can i do by using : <xs:pattern value="[a-zA-Z0-9_]+"/> > > But here's the twist: In addition the validation should not allow the > following values: "john", "eric" or "kim" > > I've come up with the following regex but cant use it in the xsd: > <xs:pattern value="^(?!(john$|mariusz$|.*\W.*))/i"/> > > I get the error: "Schema error - invalid regular expression: \ expected at > position 2" > > Please help! > | ![]() | ![]() | ![]() |
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | |||||
|
