I was wrong - my apologies.
Each fragment gets its own score. And, if you're wondering, the score for the
document is equal to the score of the highest-scoring fragment for a given
search.
But this doesn't change my recommendation that you not use fragments. :)
Kelly
Thanks for your suggestions, I will definitely try to do this. Also it makes
distributing XML "documents" easier to people via email and such if I can send
them a couple small files rather then a 500MB file and say "Look for element
xxxx"
Question though. You say I cant use score with the fragmentation model ? I'm
confused. The document for score seems to imply otherwise. ---- quote ----
cts:score( [$node as node()] ) as xs:integer
Summary:
Returns the score of a node, or of the context node if no node is provided.
Parameters:
$node (optional): A node. Typically this is an item in the result sequence of a
cts:search operation.
Usage Notes:
Score is computed according to the scoring method specified in the cts:search
expression, if any.
If you run cts:score on a constructed node, it always returns 0; it is
primarily intended to run on nodes that are the retrieved from the database (an
item from a cts:search result or an item from the result of an XPath expression
that searches through the database).
Example: (: run this on the Shakespeare content set :) for $hit in
cts:search(//SPEECH, cts:word-query("with flowers"))[1 to 10] return element
hit { attribute score { cts:score($hit) }, $hit }
----------------
This to me seems to imply that cts:score() works on nodes as well as documents.
I have found using cts:search() that the scoring and sorting of the return
values definately works even when all nodes are found within the same document.
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general