You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-dev@xml.apache.org by Pe...@tietoenator.com on 2002/05/02 16:16:47 UTC

FW: XPath - Limiting the number of results returned

Hi,

Reposting this to dev - since I've had no answer to this question yet ..

Thanks for your attention in advance,
Peter

-----Original Message-----
From: Peter.Burgess@tietoenator.com
[mailto:Peter.Burgess@tietoenator.com]
Sent: 02 May 2002 10:23
To: xindice-users@xml.apache.org
Subject: XPath - Limiting the number of results returned


Hi,

I'm currently using Xindice to store metadata for an ebXML registry
implementation, and have come across an issue when using XPath to query the
contents of a collection. In some cases (using wildcard searches or common
keys), I can get back very large sets of matching results (say 1000 +
fragments). For performance reasons, I would like to limit the number of XML
fragments returned to say no more than 50 - is there anyway this support can
be added to Xindice (I could make the code change myself if needed)? What
I'm looking for is a way to interrupt an XPath query operation once the
specified maximum number of matches (i.e. 50) has been reached, and then
return that set of matched fragments. 

Also, is it possible to return 50 results and then cache all other matches
in the background so that the user can quickly access other results if
needed, once they've reviewed the first 50 results. I'm looking for the kind
of functionality provided by most search engines, where the user can specify
how many results they want to see, and can also move through the result set
page by page, without the extra overhead of waiting for all 1000 + results
to be found (which can take ages with large documents)... 

Any help would be greatly appreciated.

-- Peter