[Koha-devel] SearchMarc.pm

paul POULAIN paul.poulain at free.fr
Sat Mar 6 12:53:04 CET 2004


Chris Cormack wrote:

>Hi All
>
>Especially Joshua. Ive been thinking on starting work on Query.pm our top
>level search module.
>And im thinking of using Joshua's SearchMarc.pm module as one (if not its
>main) backend.
>
Joshua is right. i'm the author of CVS SearchMarc.pm
we did some tests a feww weeks ago to improve it.

>Heres what im thinking
>Query.pm creates an object. On creating the kohaquery
>object you pass it a string which describes your search. Pat and Steve were
>discussing perhaps using a syntax like googles.
>Eg something like
>my $query=Query::new("title: elephants (author: johnson | author: tonnesen)") 
>you then can do things like
>$num_of_results=$query->count();
>my $results=$query->results(-sortby => 'title', -limit=>10, -offset=>'10');
>
>So the Query module does all the hard work, and then all search.pl needs to
>do is craft the search string.
>So making new searches, or searching new combinations of data should be easy.
>
>Now joshua has written a module SearchMarc.pm which searches the marc tables
>to return data, so I was thinking of using Query.pm to parse the
>searchstring and construct the appropriate variables to call catalogsearch
>in SearchMarc
>Good, Bad, stupid idea?
>
Good.
I'm working at the moment on SearchMarc.pm itself.
My roadmap was the following :
1 modify it to use faster indexes. We already did some tests with 
Nelsonville.
2 modify it to add "seealso" feature. With see also, you can define in 
MARC parameters other fields that can be searches when the 1st is asked. 
For example : author (200$a => also search 701$a, 702$a, 703$a)
It's what Joshua speaks about when he says :

"For instance, rather than using Koha's title table to retrieve title information for display
on the results screen I would like to grab: 245a, b, h, 246a, 295c"

Those 2 are done & commited a few minuts ago.
3 modify search to add "order by feature". the order must be choosen in 
a biblio or biblioitem field.
4 add "store query in my session" (through cookie) => to be able to 
modify the last cookie.
5 add next & previous feature in MARCdetail.pl
6 add "store up to 5 previous queries".
7 modify opac to use marc search & drop "quick search in Librarian 
interface)

The 1st 3 steps are fully compatible with Chris ideas. They are on a 
lower level. So I propose to work on SearchMarc itself, and Chris or 
someone else on higher level (including point 4-6 of this mail)

I leave Marseille for Belgium tommorow afternoon. I'll be back on 
wednesday. I won't work on those features until then to avoid working on 
something that someone else works too)

Instead, i think i'll work on some code cleaning in circulation or 
members module.


END NOTE : shouldn't we organize a irc meeting to officially "elect" 2.0 
release maintainer & 2.2 release manager ?
afaik, we have slef as 2.0RM & me as 2.2RM ?
(the 2.0RM could be nominated when official 2.0.0 is released (i still 
take care of 2.0.0, as promised). That's a question of days : i'm just 
waiting for polish & chinese translation & some feedbacks on 
z3950clients. Seems that this points is better)

-- 
Paul POULAIN
Consultant indépendant en logiciels libres
responsable francophone de koha (SIGB libre http://www.koha-fr.org)






More information about the Koha-devel mailing list