archive search error: Column 'description' ambiguous

Started by hymeno, 29 April 2019, 13:02:18

Previous topic - Next topic
A financial contribution is greatly appreciated as a support, to help us to keep live the project.
If you like this project you can donate some piece of BitCoin to this address: bc1qy5tgq6tvrckac2a57unxvqcnxamrvhduve9sj9

hymeno

hi,

there could be a little archive search error:

Search - Alexandria Book Library
Search in booklists
Archived Books: "On"

that creates with the J!-search a:
Column 'description' in field list is ambiguous

regards,
hym

(latest J! & abbook)

A financial contribution is greatly appreciated as a support, to help us to keep live the project.
If you like this project you can donate some piece of BitCoin to this address: bc1qy5tgq6tvrckac2a57unxvqcnxamrvhduve9sj9

federica

Many thanks for your notice!

To fix this bug you have to modify plugins/search/book/book.php line 198
from
.'description AS text,'
to
.'a.description AS text,'

I will fix the bug in the next release.
Al mondo ci sono 10 tipi di persone, quelli che hanno capito il codice binario e quelli che non l'hanno capito.
[url=http://www.antivirushelp.it]http://www.antivirushelp.it[/url]
[url=http://www.disconnessi.org]stacca la spina![/url]

hymeno

thx for the quick reply
mmh ...
this changes the error messages
Unknown column 'a.publish_up' in 'where clause'
???

hymeno

I quote out that
// .'AND (a.publish_up = '.$db->Quote($nullDate).' OR a.publish_up <= '.$db->Quote($now).') '
// .'AND (a.publish_down = '.$db->Quote($nullDate).' OR a.publish_down >= '.$db->Quote($now).')'
then the search works, but for a click on an archived entry, then unfortunately I get a
View not found [name, type, prefix]: archive, html, abookView
...  :-\



A financial contribution is greatly appreciated as a support, to help us to keep live the project.
If you like this project you can donate some piece of BitCoin to this address: bc1qy5tgq6tvrckac2a57unxvqcnxamrvhduve9sj9

federica

Modify also line 206 and 207
from:
.'AND (a.publish_up = '.$db->Quote($nullDate).' OR a.publish_up <= '.$db->Quote($now).') '
.'AND (a.publish_down = '.$db->Quote($nullDate).' OR a.publish_down >= '.$db->Quote($now).')' );

to
);

Now it is ok?
Al mondo ci sono 10 tipi di persone, quelli che hanno capito il codice binario e quelli che non l'hanno capito.
[url=http://www.antivirushelp.it]http://www.antivirushelp.it[/url]
[url=http://www.disconnessi.org]stacca la spina![/url]

hymeno

Yes. Thank you!

(the a.publish_up- and the view-error did not occur after a while ?? ... so i don't comment it out)

regards