[Koha] help writing report

ksckemperman at chartermi.net ksckemperman at chartermi.net
Thu Feb 24 04:48:45 NZDT 2011


I am *trying* to create some reports for teacher/library use. What I 
need is a report that will list for each teacher the students names and 
the book(s) they have checked out today.  I'd like it to read something 
like this:

borrower category, borrower #, surname, first name, title of book, 
barcode, date checked out

I have written this report, which is getting close to what I want, but 
the title of the book is not coming up (do I have the wrong value for 
that column?) and instead of reporting just the books that are currently 
checked out, the report lists every book in that student's history.  Can 
someone help me to correct it?   I am using the build new reports 
function because I don't really understand the whole SQL thing  :)

SELECT 
borrowers.categorycode,borrowers.borrowernumber,borrowers.surname,borrowers.firstname,biblioitems.collectiontitle,items.barcode,items.datelastborrowed 
FROM borrowers LEFT JOIN statistics on 
(statistics.borrowernumber=borrowers.borrowernumber) LEFT JOIN items on 
(items.itemnumber = statistics.itemnumber) LEFT JOIN biblioitems on 
(biblioitems.biblioitemnumber = items.biblioitemnumber)   WHERE 
borrowers.categorycode='3RD'


2nd question - how do I clear a patron's circulation history?  I have 
been using my daughter's # to practice/test different functions and now 
she has a history that is not accurate.

Thank you,
Shelley
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.katipo.co.nz/pipermail/koha/attachments/20110223/733f4d90/attachment.htm 


More information about the Koha mailing list