https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=38225

            Bug ID: 38225
           Summary: Catalog statistics report shows incorrect total when
                    library has both blank and null values in an item
                    column
 Change sponsored?: ---
           Product: Koha
           Version: Main
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P5 - low
         Component: Reports
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]

To recreate:
1 - Browse to Reports->Catalog
2 - Set columns = homelibrary = Centerville
3 - Set row = Collection
4 - Set Cell Value to Count total items
5 - Set Output to To the screen
6 - Run, note columsn match
7 - Change some values in the DB:
    UPDATE items SET ccode="" WHERE ccode='REF' and barcode LIKE '%35';
8 - Run report again, off by one
9 - Edit the code in the script and set:
    our $debug=1
10 - Copy the code from the logs and add the library, or run the command below
where I did that already:
    SELECT items.ccode, items.homebranch,  COUNT(*)          FROM items        
LEFT JOIN biblioitems ON (items.biblioitemnumber =
biblioitems.biblioitemnumber)         LEFT JOIN biblio ON
(biblioitems.biblionumber = biblio.biblionumber)         WHERE 1  AND
items.homebranch LIKE 'CPL'  group by items.ccode, items.homebranch order by
items.ccode,items.homebranch;
11 - Note the row with no value and total 5 - it is missing on the report in
the interface, instead NULL has been shown twice - the value overwritten and
causing a mismatch in totals

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to