Skip to main content.
home | support | download

Back to List Archive

Re: Ranking problem in second iteration of results

From: <moseley(at)not-real.hank.org>
Date: Tue Nov 18 2003 - 03:17:44 GMT
On Mon, Nov 17, 2003 at 05:24:47PM -0800, PFinch@cch.com.au wrote:
> Hi,
> 
> I'm using the Swish-e C API and I'm having a problem with
> the ranking. I have to iterate over the results 2 times and for
> some reason the second pass through the results I get back
> incorrect ranks for the document. Does anyone have any ideas
> on what night be wrong please?

Not yet.

Try running the libtest program.  Change to the src directory in the 
distribution and run "make libtest".  I think by default libtest sorts 
by swishtitle, so you should probably change that to rank before running 
"make libtest".  libtest opens index.swish-e in the current directory.

I just compared results from the swish-e binary, the C API (using 
libtest) and also the SWISH::API module and all presented the same rank.

But that's all with swish-e version 2.4.  The code below if for the old 
API, right?  I'd recommend using the new API.  The more testers the 
better...  The API docs could more reviewing, too.


> for(nRun = 0; nRun < 2; nRun++)
> {
> SwishSearch(
>             pConfig->pSwish,
>             pConfig->szSwishQueryString,
>             1,
>             NULL,
>             NULL) ;
>  SwishSeek(pConfig->pSwish, pConfig->nStartAtResult - 1) ;
>  while((pConfig->pCurrentResult = SwishNext(pConfig->pSwish))!=NULL)
> {
>       yadayadayada()
> }
> }

-- 
Bill Moseley
moseley@hank.org
Received on Tue Nov 18 03:17:48 2003