[Koha-bugs] [Bug 14861] Accession date comparison does not work in advanced search

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Sep 29 02:06:28 CEST 2015


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14861

--- Comment #3 from David Cook <dcook at prosentient.com.au> ---
(In reply to Barton Chittenden from comment #2)
> Ok, this is from my ccl.properties:
> 
> Date-of-acquisition 1=32
> Date-of-acquisition 1=Date-of-acquisition r=o
> acqdate Date-of-acquisition
> 
> Given an item where acqdate is 2011-09-07,
> 
>   search.pl?idx=acqdate%2Cst-date-normalized&q=2011-09-07
> 
> works, but querying the entire month from 2011-09-01 to 2011-09-30 does not:
> 
>   search.pl?idx=acqdate%2Cst-date-normalized&q="2011-09-01+-+2011-09-30"
> 
> Returns no results.

Barton, are you using the advanced search or the regular search box? It looks
like the advanced search to me.

The problem I see is that your query is being wrapped in double quotation
marks.

No results:
/cgi-bin/koha/catalogue/search.pl?idx=acqdate%2Cst-date-normalized&q="2010-01-01+-+2015-01-01"&idx=kw&idx=kw&sort_by=relevance

Lots of results:
/cgi-bin/koha/catalogue/search.pl?idx=acqdate%2Cst-date-normalized&q=2010-01-01+-+2015-01-01&idx=kw&idx=kw&sort_by=relevance

Here are two examples of it working in the staff client and opac when using
free-form CCL queries:
/cgi-bin/koha/catalogue/search.pl?q=acqdate%2Cst-date-normalized%3A2010-01-01+-+2015-01-01
/cgi-bin/koha/opac-search.pl?q=acqdate%2Cst-date-normalized%3A2010-01-01+-+2015-01-01&branch_group_limit=

--

I've seen this sort of problem before on Bywater Koha sites...

I just tried using the Advanced Search in Koha master and I got the following
URL, which matches my working URL above.
/cgi-bin/koha/catalogue/search.pl?idx=acqdate%2Cst-date-normalized&q=2010-01-01+-+2015-01-01&idx=kw&idx=kw&sort_by=relevance

Are you trying this query on the Koha used by Bywater or the Koha master
branch? I'm guessing Bywater has a local patch which quotes values and that's
creating the problem.

I'm going to poke around a bit more with yaz-client to see if I can find out
more...

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list