This explains some of the results I've been getting for month end circ reports! Any suggestions on how to modify the following SQL to query items and deleteditems? What would the JOIN be?<br><br>SELECT items.ccode AS Collection, COUNT( statistics.itemnumber ) AS Count, Branch AS BRANCH FROM statistics LEFT JOIN items ON (statistics.itemnumber = items.itemnumber) WHERE statistics.type IN ('issue') AND year(statistics.datetime) = '__YEAR__' and month(statistics.datetime) = '__MONTH__' GROUP BY branch, items.ccode<br>
<br>Any help would be appreciation!<br><br clear="all">Susan Bennett<br>ILS System Administrator<br>Geauga County Public Library<br>440 286-6811 x 125<br>440 286-7419 FAX<br>
<br><br><div class="gmail_quote">On Wed, May 12, 2010 at 2:20 PM, Cab Vinton <span dir="ltr"><<a href="mailto:bibliwho@gmail.com">bibliwho@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Wed, May 12, 2010 at 1:58 PM, Owen Leonard <<a href="mailto:oleonard@myacpl.org">oleonard@myacpl.org</a>> wrote:<br>
<br>
> What you'll need to remember when tracking those statistics is that if<br>
> you want to pull information about those deleted items along with the<br>
> statistical data (e.g. how many DVDs you circulated in 2006), you'll<br>
> have to query both the items table *and* the deleteditems table.<br>
<br>
</div>Oof. That doesn't sound like much fun. So we might end up having to<br>
modify a slew of different reports.<br>
<br>
Sounds like we're better off using the WITHDRAWN, LOST, etc. item statuses ...<br>
<br>
Thank you, Owen.<br>
<div class="im"><br>
Cab Vinton, Director<br>
Sanbornton Public Library<br>
Sanbornton, NH<br>
_______________________________________________<br>
</div><div><div></div><div class="h5">Koha mailing list<br>
<a href="mailto:Koha@lists.katipo.co.nz">Koha@lists.katipo.co.nz</a><br>
<a href="http://lists.katipo.co.nz/mailman/listinfo/koha" target="_blank">http://lists.katipo.co.nz/mailman/listinfo/koha</a><br>
</div></div></blockquote></div><br>