[Koha] Report of Active Users for a Month

Melanie Hedgespeth melanie at salpublib.org
Wed Nov 4 08:23:34 NZDT 2009


Thanks.

Does issue date refer to the date the item was checked out?

 

I’m getting just a handful of issues so I’m off somewhere on it.

 

Thanks.

 

Melanie



  <http://www.facebook.com/pages/Salina-KS/Salina-Public-Library/91712193139?ref=s> 

 

From: Jesse [mailto:pianohacker at gmail.com] 
Sent: Tuesday, November 03, 2009 1:20 PM
To: Melanie Hedgespeth
Cc: koha at lists.katipo.co.nz
Subject: Re: [Koha] Report of Active Users for a Month

 

 

2009/11/3 Melanie Hedgespeth <melanie at salpublib.org>

I am trying to create a report for active patrons within a specific month, divided up by patron category.

 

(I see you can create a patron statistics report for patron activity within “years”, but can’t get the code so I can adjust it to a month’s period.)  

 

Any tips?

 

Thanks!

 

Melanie Hedgespeth

Tech Center Manager

Salina Public Library

785.825.4624 Ext. 233

melanie at salpublib.org

 


I assume by "active", you mean "checked out books", right? If so, you'd want something like this:

SELECT YEAR(issuedate), MONTH(issuedate), categorycode, COUNT(DISTINCT borrowernumber) FROM old_issues LEFT JOIN borrowers USING (borrowernumber) GROUP BY YEAR(issuedate), MONTH(issuedate), categorycode;

Because it uses old_issues, it won't include anything that's still checked out; getting around that requires either ugly subqueries or running the report with old_issues and issues and manually combining the results.

-- 
Jesse Weaver

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.katipo.co.nz/pipermail/koha/attachments/20091103/d776796a/attachment-0001.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/gif
Size: 2556 bytes
Desc: image001.gif
Url : http://lists.katipo.co.nz/pipermail/koha/attachments/20091103/d776796a/attachment-0001.gif 


More information about the Koha mailing list