Bug 33081 - (Bug 31314 follow-up) Placing a hold on a serial generates DBI Exception
Summary: (Bug 31314 follow-up) Placing a hold on a serial generates DBI Exception
Status: RESOLVED DUPLICATE of bug 32674
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: 22.11
Hardware: All All
: P2 major (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-27 21:38 UTC by Janusz Kaczmarek
Modified: 2023-02-28 08:13 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Janusz Kaczmarek 2023-02-27 21:38:52 UTC
In 22.11, apparently after applying bug 31314 (perhaps in conjunction with Bug 31306), placing a hold (from OPAC: opac-reserve.pl) on a serial record (i.e. a MARC 21 record with 942 $s set) generates runtime error and produces in opac-error.log the following info: 

DBI Exception: DBD::mysql::st execute failed: Column 'biblionumber' in 
where clause is ambiguous


It seems that this is caused by the presence of 'serialid.publisheddate' in the line:

order_by => [ 'serialid.publisheddate', 'me.enumchron' ]
Comment 1 Janusz Kaczmarek 2023-02-27 21:40:22 UTC
In 22.11, apparently after applying bug 31314 (perhaps in conjunction with Bug 31306), placing a hold (from OPAC: opac-reserve.pl) on a serial record (i.e. a MARC 21 record with 942 $s set) generates runtime error and produces in opac-error.log the following info: 

DBI Exception: DBD::mysql::st execute failed: Column 'biblionumber' in 
where clause is ambiguous


It seems that this is caused by the presence of 'serialid.publisheddate' in the line:

order_by => [ 'serialid.publisheddate', 'me.enumchron' ]

in Koha::Items::search_ordered.
Comment 2 Jonathan Druart 2023-02-28 08:13:17 UTC

*** This bug has been marked as a duplicate of bug 32674 ***