[Koha-bugs] [Bug 28524] New: Most-circulated items (cat_issues_top.pl) is failing with MySQL 8

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Jun 7 23:14:15 CEST 2021


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

            Bug ID: 28524
           Summary: Most-circulated items (cat_issues_top.pl) is failing
                    with MySQL 8
 Change sponsored?: ---
           Product: Koha
           Version: 21.05
          Hardware: All
                OS: All
            Status: NEW
          Severity: critical
          Priority: P5 - low
         Component: Reports
          Assignee: koha-bugs at lists.koha-community.org
          Reporter: development at cm-portimao.pt
        QA Contact: testopia at bugs.koha-community.org

CGI::Compile::ROOT::usr_share_koha_intranet_cgi_2dbin_reports_cat_issues_top_2epl::calculate():
DBI Exception: DBD::mysql::st execute failed: You have an error in your SQL
syntax; check the manual that corresponds to your MySQL server version for the
right syntax to use near 'RANK, biblio.biblionumber AS ID, itemcallnumber as
CALLNUM, ccode as CCODE, loca' at line 1 [for Statement "SELECT DISTINCT
biblio.title, COUNT(biblio.biblionumber) AS RANK, biblio.biblionumber AS ID,
itemcallnumber as CALLNUM, ccode as CCODE, location as LOC FROM `old_issues`
                  LEFT JOIN items USING(itemnumber)
                  LEFT JOIN biblio USING(biblionumber)
                  LEFT JOIN biblioitems USING(biblionumber)
                  LEFT JOIN borrowers USING(borrowernumber)
                  WHERE 1 AND old_issues.issuedate > '2021-01-01' AND
old_issues.issuedate < '2021-06-30' AND old_issues.branchcode like 'p' group by
biblio.biblionumber order by RANK DESC"] at
/usr/share/koha/intranet/cgi-bin/reports/cat_issues_top.pl line 67

Rank is a MySQL reserved word defined in MySQL version 8.0.2

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.


More information about the Koha-bugs mailing list