I decided to go ahead and try to implement prompting for the year inside of the Koha report and here's the SQL I came up with (enter the year twice when prompted):
SELECT month(returndate) AS `MONTH`, COUNT(*) AS `OVERDUES` FROM old_issues WHERE returndate > date_due AND returndate > concat(<<START YEAR (yyyy)>>,'-01-01 00:00:00') AND returndate < concat(<<END YEAR (yyyy)>>,'-12-31 23:59:59') GROUP BY month(returndate) WITH ROLLUP; Perhaps this may be a useful report to others..."Number of overdues per month". You can actually enter a different "start year" and "end year" and it still shows the number of overdues by month...maybe you'll see some trends where patrons are consistently returning items late in one particular month??? Steve _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz http://lists.katipo.co.nz/mailman/listinfo/koha