[Koha] Help with sql statement.

James Ghiorzi JGhiorzi at cosb.us
Sun Jun 10 04:24:07 NZST 2012


Hello everyone,

I am trying to get the new patron report developed by Sharon Moreland, to do a date range and have a location selection for San Benito County Free Library.  I am sure I am doing something wrong, please advise as necessary,

SQL:

SELECT b.code,c.code,COUNT(*)
FROM borrowers WHERE DATE(dateenrolled)  between <<Date
between (yyyy-mm-dd)>> AND DATE(dateenrolled)= <<and (yyyy-mm-dd)>> and b.code=<<Pick your branch|branches>>
GROUP BY c.code

Thank you for your patience and understanding,

James Ghiorzi
Data Management Coordinator
Martin Luther King Jr. Library
San Jose State University


More information about the Koha mailing list