]> git.koha-community.org Git - koha.git/commit
Bug 20144: [sql_modes] Fix GROUP BY clause in GetBasketsInfosByBookseller
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 6 Feb 2018 14:54:18 +0000 (11:54 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 13 Feb 2018 16:58:57 +0000 (13:58 -0300)
commit2e35da4f6b0e2c25ca1e6acb3e80f8b9d65cb658
treed1755f04cb77976d98020e9e9cbdf9e4832e7eb2
parent406a480a780e67d3386e354907f8fac674257c17
Bug 20144: [sql_modes] Fix GROUP BY clause in GetBasketsInfosByBookseller

This need to be tested from the interface!

Fix for:
'koha_kohadev.aqbasket.basketname' isn't in GROUP BY

t/db_dependent/Acquisition/GetBasketsInfosByBookseller.t

We need this group by.
We should not need to list all fields, from mysql 5.7 doc:
https://dev.mysql.com/doc/refman/5.7/en/group-by-handling.html
"The query is valid if name is a primary key of t or is a unique NOT NULL column. In such cases, MySQL recognizes that the selected column is functionally dependent on a grouping column. "

However, MariaDB did not implemented yet:
https://jira.mariadb.org/browse/MDEV-11588

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
C4/Acquisition.pm