W3C home > Mailing lists > Public > public-qt-comments@w3.org > March 2009

[Bug 6665] [FT] Test Suite Bugs

From: <bugzilla@wiggum.w3.org>
Date: Mon, 09 Mar 2009 20:00:24 +0000
To: public-qt-comments@w3.org
Message-Id: <E1LgleC-00034X-H5@wiggum.w3.org>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=6665


Michael Dyck <jmdyck@ibiblio.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jmdyck@ibiblio.org




--- Comment #1 from Michael Dyck <jmdyck@ibiblio.org>  2009-03-09 20:00:24 ---
> [5] examples-362-4.xq
> 
> I wouldn't expect any results for
>     [. ftcontains "efficient" ftand ftnot "and" window 2 words]
> as "and" directly follows the term "efficient" - but I might be wrong

So you're thinking it means something like:
    the book contains an occurrence of 'efficient' that doesn't have
    an occurrence of 'and' within any 2-word window of it
But in fact it means something like:
    the book has a 2-word window that contains an occurrence of
    'efficient' and no occurrence of 'and'
which succeeds because of the words "enable efficient".

In terms of the section 4 semantics, the FTAnd
    "efficient" ftand ftnot "and"
generates a single Match, containing a StringInclude for the occurrence of
'efficient' and three StringExcludes, one for each occurrence of 'and' in
the book's string-value. This Match is passed to the fts:ApplyFTWordWindow
function to apply the
    window 2 words
filter. It constructs every 2-word window that contains all the
StringIncludes in the Match (there are two, one for "enable efficient"
and one for "efficient and") and for each, generates a Match containing
the StringInclude for 'efficient', and all the StringExcludes that fall
within the window. (For the "enable efficient" window, there are no
StringExcludes; for the "efficient and" window, there is one.) At the top
level, fts:FTContainsExpr looks for a Match containing no StringExcludes,
finds one, and so yields true.


> [29] ftstaticcontext-q5.xq
> 
> I would expect an error here as both "case sensitive" and "case
> insensitive" are specified (but, as usual, I can easily be wrong).

The test was constructed to counter that expectation. You're presumably
expecting FTST0019, defined in Section 3.4:
    It is a static error [err:FTST0019] if, within a single FTMatchOptions,
    there is more than one match option of any given match option group.
    For example, if the FTCaseOption "lowercase" is specified, then
    "uppercase" cannot also be specified as part of the same
    FTMatchOptions.
The thing to note is that the constraint only applies within a single
FTMatchOptions. In the test case:
    declare ft-option case sensitive;
    declare ft-option with stemming case insensitive;
there are two FTOptionDecls, each containing its own FTMatchOptions. Within
each FTMatchOptions, there are no match option conflicts, so no error.


-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Monday, 9 March 2009 20:00:33 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:14:56 GMT