[Koha-zebra] Scan problem.

Henri-Damien LAURENT henridamien at koha-fr.org
Mon Oct 29 19:16:33 CET 2007


Mike Taylor a écrit :
> Henri-Damien LAURENT writes:
>  > the latest question I found a workaround :
>  >   my $scan= $conn->scan_pqf('@attr 1=21 @attr 6=3 @attr 5=102 @attr 8=1
>  > "[A-z0-9]"');
>  > That way, I can get all the publishers.
>
> Hmm.  But if you start your scan from the just "a" that will yield the
> same start-point.  Remember that the term in a scan "query" is not
> searched for, just used as a start-point within the list of all
> terms.  If you want to start from the very beginning, you should
> probably use the empty search-term "", which sorts to the start.
>   
>  > This query was wrong because no search parameter. I corrected it.
>
> And is it working?
>   
empty search term is not working.
What works best is "0".

>  > >From perldoc ZOOM :
>  >  number [default: 10]
>  >            Indicates how many terms should be returned in the ScanSet. 
>  > The number actually returned may be less, if the start-point is near the
>  > end of the index, but will not be greater.
>  > I tried to set number to 100 this way
>  >   $conn->option(preferredRecordSyntax => "usmarc",number=>100);
>  > 
>  > And got only 10 results.
>  > Am I doing wrong ?
>
> For some reason, you can't set multiple options in a single call like
> this: the second and subsequent are ignored.  Use:
>    $conn->option(preferredRecordSyntax => "usmarc");
>    $conn->option(number=>100);
>   
Thanks for this very valuable information.
It works now.
>  > Is there a way to order "scanned" term on hit count ?
>
> Not that I know of.  If there is a way, it's Zebra-specific, and Adam
> will be the one who knows about it.
>   
Let us wait his advice on that then.

-- 
Henri Damien LAURENT et Paul POULAIN 
Consultants indépendants 
en logiciels libres et bibliothéconomie (http://www.koha-fr.org)






More information about the Koha-zebra mailing list