[Xapian-discuss] Multiple matches in the same file

Olly Betts olly at survex.com
Fri May 11 04:48:09 BST 2007


On Sun, May 06, 2007 at 08:36:59PM +0200, Pedro Fortuny Ayuso wrote:
> The "problem" I wanted to state (informally, not technically) is: If you
> search "banana", not just getting a list of the documents (web pages,  
> for example) where banana appears (this is what google does), but a list
> of [documents + places] where it appears. That would mean, documents
> appear a lot of times for the same query.

You can look at the positions in a particular document where "banana"
appears using PositionIterator.  But there's not any mechanism for
looking at where a Query or a group of terms appear in a document.  It
should be possible to add one, but it needs some criteria for what it
means for a Query to match a position in a document.

Cheers,
    Olly



More information about the Xapian-discuss mailing list