RE: [XQuery] MS-XQ-LC1-140

> 
> "The default collation applies to all functions that require 
> a collation, except the following functions: fn:contains, 
> fn:starts-with, fn:ends-with, fn:substring-before, and 
> fn:substring-after. If one of these functions is called 
> without an explicit collation parameter, it uses the Unicode 
> codepoint collation rather than the default
> collation.": Why are these functions treated differently. We 
> think that this is more confusing than helpful and request to 
> not special-case them and have them take the default 
> collation as well.
>
For the record, we debated this point at some length, and had input from
the I18N group on the topic. The reasons were a combination of
usability, efficiency, implementability, and backwards compatibility.
Not all collations support substring matching; and where they do, they
can give very strange results that can only be understood by users who
appreciate the subtleties of Unicode normalization and decomposition.
Also, it brings these functions into line with the regex functions such
as matches, which do not use collations.

Michael Kay 

Received on Tuesday, 17 February 2004 10:20:01 UTC