It's supposed to exclude the escaped ampersand, escaped less than and the space 
character.

--- In rng-users@yahoogroups.com, "G. Ken Holman" <gkhol...@...> wrote:
>
> At 2009-12-21 02:40 +0000, dan.isla wrote:
> >I was wondering if it was possible to do a negative look-ahead 
> >pattern match with Relax NG.
> >
> >I am trying to exclude certain strings. The pattern works fine in 
> >other languages (Ruby) but fails with RNG.
> >
> >Here is my definition:
> >
> >xsd:string { pattern = "^(?!^.*((&amp;)|(&lt;)| ).*$).*$" }
> 
> That doesn't look correct to me ... are you not missing a third 
> operand in the embedded expression?
> 
>    ((&amp;)|(&lt;)| )
> 
> ... that is the choice between an ampersand, a less-than, and what?
> 
> Mind you, that is just with visual inspection ... I haven't tried to 
> run it with software. (and it is early in the morning so I might be 
> missing something!)
> 
> I hope this helps.
> 
> . . . . . . . . . . Ken
> 
> --
> UBL and Code List training:      Copenhagen, Denmark 2010-02-08/10
> XSLT/XQuery/XPath training after http://XMLPrague.cz 2010-03-15/19
> XSLT/XQuery/XPath training:   San Carlos, California 2010-04-26/30
> Vote for your XML training:   http://www.CraneSoftwrights.com/r/i/
> Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/r/
> Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
> Video lesson:    http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
> Video overview:  http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
> G. Ken Holman                 mailto:gkhol...@...
> Male Cancer Awareness Nov'07  http://www.CraneSoftwrights.com/r/bc
> Legal business disclaimers:  http://www.CraneSoftwrights.com/legal
>


Reply via email to