Hi all, I have a library that wants to alter this report to allow us to limit on the item's home branch:
SELECT concat(b.title, ' ', ExtractValue(m.marcxml, '//datafield[@tag="245"]/subfield[@code="b"]')) AS title, b.author, count(h.reservedate) AS 'holds' FROM biblio b LEFT JOIN biblioitems m USING (biblionumber) LEFT JOIN reserves h ON (b.biblionumber=h.biblionumber) GROUP BY b.biblionumber HAVING count(h.reservedate) >= <<Min number of holds>> The problem as I see it is that the hold is placed on the bib level - not the item level most of the time. Can you tell me how to bring the items table in here even if the hold is on the bib level and get the right numbers? Nicole _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz http://lists.katipo.co.nz/mailman/listinfo/koha