Hi Daniel,

On May 5, 2011, at 3:03 PM, Grobani, Daniel wrote:
> In the course of trying to devise a CCL query that will display books 
> acquired by a branch in the last 30 days, I've found that compound queries 
> don't seem to work the way I expect them to. I don't know if this is due to 
> my misunderstanding or because I'm on LLEK.
> 
> For example, I think the following should return all biblios having at least 
> one item whose acqdate is 20011-04-13 and whose homebranch is SF:
> http://samuelmerritt.kohalibrary.com/cgi-bin/koha/opac-search.pl?q=ccl%3Dacqdate%3D2011-04-13+and+branch%3DSF.
> 
> This returns one biblio with five items, but the only item with 
> acqdate=2011-04-13 has branch=OAK, and the only item with branch=SF has 
> acqdate=2009-06-17.
> 
> Have I specified the syntax incorrectly?

No, the syntax is correct.  What you're running into is the fact that the 
search engine is indexing the entire bib record, including item records, and 
the search itself is searching bibs, not items.  Consequently, since the bib 
record in question meets both conditions of the query (i.e., it has a 952 
containing a branch subfield whose value is SF and it has a 952 containing the 
specified acq date), the entire bib is retrieved.  The bibliographic search 
engine is not currently set up to verify that queries on embedded item fields 
are all referring to the same item record.

Regards,

Galen
--
Galen Charlton
VP, Data Services
Equinox Software, Inc. / Your Library's Guide to Open Source
email:  [email protected]
direct: +1 352-215-7548
skype:  gmcharlt
web:    http://www.esilibrary.com/

_______________________________________________
Koha mailing list  http://koha-community.org
[email protected]
http://lists.katipo.co.nz/mailman/listinfo/koha

Reply via email to