While creating jeroenp / BeSharp.net / source / Native / Delphi / Scripts / GroupProj.xsd — Bitbucket, I bumped into the fact that regular expressions in XSD *or better XML Schema Regular Expressions) regular expressions are a tad different than the RegEx.
Actually, there are quite a few regular expression flavours, and all of them are a tad different. The page Compare Regular Expression Flavors at Regular-Expressions.info.
That is a great site with Regex Tutorial, Examples and Reference – Regexp Patterns by RegEx guru Jan Goyvaerts (yes, that looks Dutch, but he was born in Belgium and now lives in Phuket) famous for tools like PowerGREP and RegExBuddy. All based on the great Delphi RegEx PCRE library written by Jan and included in Delphi XE and up.
The thing that baffled me most is that even though XML Schema Regular Expressions do not support anchors ^ and $, you still have to escape them.
–jeroen