Bug 11530 - Recalculating a book's total issue count from items.issues or statistics-table with update_totalissues.pl ignores deleted_items.
Summary: Recalculating a book's total issue count from items.issues or statistics-tabl...
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Command-line Utilities (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Galen Charlton
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-13 15:14 UTC by Olli-Antti Kivilahti
Modified: 2020-01-28 20:22 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Olli-Antti Kivilahti 2014-01-13 15:14:07 UTC
--------------------------
- REPLICATING THIS ISSUE -
--------------------------

If we had a biblio, with 4 items, each being issued 50 times.
Running the update_totalissues.pl in stats or items -mode would yield a biblioitems.totalissues value of 200.

If we get rid of one of the books, and recalculate, the biblioitems.totalissues value will drop to 150!

update_totalissues.pl works in incremental mode, but a recalculation will ignore deleted items.
Comment 1 Fridolin Somers 2020-01-28 08:50:37 UTC
Since statistics contains only itemnumber, once item deleted we can not link this itemnumber to its biblionumber.
Comment 2 Katrin Fischer 2020-01-28 20:22:09 UTC
(In reply to Fridolin SOMERS from comment #1)
> Since statistics contains only itemnumber, once item deleted we can not link
> this itemnumber to its biblionumber.

What we do is use a union of items and deleteditems in most reports - then you can.