Could uppercase/lowercase variations or diacrytics be responsible for
your false negatives?
Text searching is really a complex problem, and not one that XSL is well
On Mon, 2010-04-12 at 22:15 +0100, Robert Young Walser wrote:
> Searching our giant EAD instance with XSL is producing strange results. The EAD document includes item-level descriptions which often include multiple titles: a primary title in the <did><unittitle><title> and sometimes multiple alternate titles in <scopecontent><p><title> tags.
> We've been using xsl stylesheets to locate text in these titles using these xsl statements:
> After creating a node-set of all the items in the collection
> <xsl:for-each select=".//title">
> <xsl:if test="contains(string(.) , $SearchTitle)">
> code to display the item
> What is odd is that the results are consistent but not what I'd expect.
> The search string is only found some of the time when the test is true. In other words, the xsl consistently misses some items for which the test should be true. Any advice on tracing this mystery?
> Bob Walser
> The James Madison Carpenter Project