https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43102
--- Comment #14 from Kyle M Hall (khall) <[email protected]> --- Created attachment 209521 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=209521&action=edit Bug 43102: (QA follow-up) Trim itemnumber subqueries to a single column The itemnumber subqueries inherit the column list of the resultset they are built from, so DBIC wraps them in a derived table carrying every item column instead of a plain itemnumber subquery. They also fail outright if the resultset carries a LIMIT, as MariaDB doesn't support LIMIT inside an IN subquery. This patch moves the subquery construction into a single helper that selects only the itemnumber column and wraps the result in a derived table via as_subselect_rs so a LIMIT stays legal. The inherited ORDER BY is kept. Dropping it would make a limited resultset select an arbitrary set of items rather than the first ones in its order. The database ignores an ORDER BY in a derived table that has no LIMIT, so it costs nothing in the usual case. Test Plan: 1) Apply this patch 2) prove t/db_dependent/Koha/Items.t 3) Note all tests pass! -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list -- [email protected] To unsubscribe send an email to [email protected] website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
