[Koha] Problems while displaying search results
Abdrahamane ANNE
girlajo at gmail.com
Wed Oct 11 13:40:26 NZDT 2006
Hello,
I have just installed Koha 2.2.5 on linux ubuntu Dapper Drake with
mysql 5.0.22. After adding some records, I noticed that search results
do not display correctly. Some fields (title, ISBN, ...) are not
displayed. After some digging around, I discovered that some SQL
queries contained in C::Search and C::SearchMarc modules cannot be
executed correctly using mysqlclient.
I have made some corrections :
* C4::Search (/usr/local/koha/intranet/modules/C/Search.pm), line
1493 : I replaced the query :
Select *, biblioitems.notes AS bnotes, biblio.notes
from biblio, biblioitems
left join bibliosubtitle on
biblio.biblionumber = bibliosubtitle.biblionumber
left join itemtypes on biblioitems.itemtype=itemtypes.itemtype
where biblio.biblionumber = ?
and biblioitems.biblionumber = biblio.biblionumber
by :
Select *, biblioitems.notes AS bnotes, biblio.notes
from biblio JOIN biblioitems ON biblio.biblionumber=biblioitems.biblionumber
left join bibliosubtitle on biblio.biblionumber = bibliosubtitle.biblionumber
left join itemtypes on biblioitems.itemtype=itemtypes.itemtype
where biblio.biblionumber = ?
and biblioitems.biblionumber = biblio.biblionumber
* C4::SearchMarch (/usr/local/koha/intranet/modules/C/SearchMarc.pm),
line 343 : I replaced the query :
SELECT biblio.biblionumber as bn,biblioitems.*,biblio.*,
marc_biblio.bibid,itemtypes.notforloan,itemtypes.description
FROM biblio, marc_biblio
LEFT JOIN biblioitems on biblio.biblionumber = biblioitems.biblionumber
LEFT JOIN itemtypes on itemtypes.itemtype=biblioitems.itemtype
WHERE biblio.biblionumber = marc_biblio.biblionumber AND bibid = ?
by :
SELECT biblio.biblionumber as bn,biblioitems.*,biblio.*,
marc_biblio.bibid,itemtypes.notforloan,itemtypes.description
FROM biblio JOIN marc_biblio ON biblio.biblionumber=marc_biblio.biblionumber
LEFT JOIN biblioitems on biblio.biblionumber = biblioitems.biblionumber
LEFT JOIN itemtypes on itemtypes.itemtype=biblioitems.itemtype
WHERE biblio.biblionumber = marc_biblio.biblionumber AND bibid = ?
The problem seems to be at FROM .. line.
After modification results display correctly. I wonder, if any body
else encountred such problems and if these are bugs.
ANNE A.
More information about the Koha
mailing list