From c1c49472f46c7b4ecad77c39abb7662e6ffb908d Mon Sep 17 00:00:00 2001 From: Michael Hafen Date: Fri, 22 Aug 2008 11:12:47 -0600 Subject: [PATCH] bug: bookcount.pl pulls wrong title. Problem is sql joins on wrong columns the sql seems to assume that biblionumber and biblioitemnumber are always the same, which in my case they aren't. Signed-off-by: Galen Charlton --- C4/Biblio.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/C4/Biblio.pm b/C4/Biblio.pm index e4e2dc26b7..e98a264de1 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -539,7 +539,7 @@ sub GetBiblioItemData { my ($biblioitemnumber) = @_; my $dbh = C4::Context->dbh; my $query = "SELECT *,biblioitems.notes AS bnotes - FROM biblio LEFT JOIN biblioitems on biblio.biblionumber=biblioitems.biblioitemnumber "; + FROM biblio LEFT JOIN biblioitems on biblio.biblionumber=biblioitems.biblionumber "; unless(C4::Context->preference('item-level_itypes')) { $query .= "LEFT JOIN itemtypes on biblioitems.itemtype=itemtypes.itemtype "; } -- 2.39.5