Hi folks

I have the following report query:
----
SELECT monthname(datetime) month, type, count(datetime) as count
from statistics
where YEAR(datetime) = YEAR(NOW())
and type in ('issue', 'renew')
GROUP BY month, type
ORDER BY month(datetime)
----

This works well but I've been asked to provide a mechanism to select the year 
to run this for (I would guess similar to the construct " DATE (b.dateexpiry)  
BETWEEN <<Between (yyyy-mm-dd)|date>> AND <<and (yyyy-mm-dd)|date>>", except 
selecting only years)

Is it possible to do this? And if so, how?


With kind regards from the Dalton McCaughey Library Team

Carlos Lopez

Dalton McCaughey Library | 29 College Crescent, Parkville, VICTORIA 3052
Ph: 03 9340 8888 ext.1 | [email protected] | library.dmlibrary.org.au 

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

Reply via email to