[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:15:19 CEST 2015
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14861
--- Comment #4 from David Cook <dcook at prosentient.com.au> ---
Z> f acqdate,st-date-normalized=2010-01-01 - 2015-01-01
Sent searchRequest.
Received SearchResponse.
Search was a success.
Number of hits: 9644, setno 2
SearchResult-1: term=2010-01-01 cnt=11758, term=2015-01-01 cnt=36059
records returned: 0
Elapsed: 0.179575
Z> f acqdate,st-date-normalized="2010-01-01 - 2015-01-01"
Sent searchRequest.
Received SearchResponse.
Search was a success.
Number of hits: 0, setno 3
SearchResult-1: term=2010-01-01 - 2015-01-01 cnt=0
records returned: 0
Elapsed: 0.000754
It's because "2010-01-01 - 2015-01-01" is being treated as a single term when
it's supposed to be a range according to the CCL grammar.
http://www.indexdata.com/yaz/doc/tools.html#ccl.syntax
Elements ::= '(' CCL-Find ')'
| Set
| Terms
| Qualifiers Relation Terms
| Qualifiers Relation '(' CCL-Find ')'
| Qualifiers '=' string '-' string
-- Elements is either a recursive definition, a result set reference, a
-- list of terms, qualifiers followed by terms, qualifiers followed
-- by a recursive definition or qualifiers in a range (lower - upper).
A syntactically correct query would be the following:
acqdate,st-date-normalized=2010-01-01 - 2015-01-01
Because it's: qualifiers '=' string '-' string
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list