On Mon, Sep 10, 2012 at 02:16:59PM +0800, ???? wrote:> ADJ matches if the words appear in the same order as in the query. Now I
> focus on the performance.
>
> Test case
>
> 2 * T7200 at 2.00GHz
> 3.0GB
>
> Xapian:1.2.5
>
> About 2.3GB of database files and 250,000 documents.
>
>
> When I use ADJ mode just like "how ADJ/1 much", It cost about
15s. So my
> question is how to improve performance.
This is essentially the issue which ticket 394 is about:
http://trac.xapian.org/ticket/394
The patch there only addresses exact ordered phrases, so will help ADJ/1
but not ADJ/2 or more, or NEAR, but the same idea will work for other
queries which use positional information.
Coincidentally, I'm currently working on tidying up this patch and
getting it merged to trunk.
Cheers,
Olly