https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=38427 --- Comment #4 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Marcel de Rooy from comment #3)
TODO Resolve inconsistency in current code when using length/offset
sub select_all_authorities { $strsth.=qq{ LIMIT $length } if ($length && !$offset); $strsth.=qq{ LIMIT $offset,$length } if ($length && $offset);
sub select_all_biblios { $strsth.=qq{ LIMIT $length } if ($length && !$offset); $strsth.=qq{ LIMIT $offset,$length } if ($offset);
Awful but passing an offset without a limit requires something like 2^64-1: SELECT * FROM somewhere LIMIT 18446744073709551615 OFFSET 5 Surely we can pass the total number of records here like: + $length ||= ( $record_type eq 'biblio' ? Koha::Biblios->count : Koha::Authorities->count ); -- You are receiving this mail because: You are watching all bug changes.