You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Mandar Deshpande <ma...@ebi.ac.uk> on 2017/05/16 15:13:49 UTC
Help reviewing json facet api query
Hi,
Could anyone please help reviewing the below json facet api query.
After updating to json facet api we are getting strange results in which the
count
(uniqueCount) for the first facet bucket is correct and the remaining are
either 0 or incorrect.
Below are the both the solr query urls:
Old query (with correct results)
http://wwwdev.ebi.ac.uk/pdbe/search/pdb/select?group=true&group.field=pdb_id
&group.ngroups=true&group.facet=true&facet=true&rows=0&facet.limit=100&facet
.mincount=1&facet.sort=count&json.nl=map&facet.field=detector&facet.field=ex
perimental_method&facet.range=deposition_year&f.deposition_year.facet.range.
start=1970&f.deposition_year.facet.range.end=2050&f.deposition_year.facet.ra
nge.gap=5&f.deposition_year.facet.range.other=between&f.deposition_year.face
t.range.include=upper&q=text%3Ahemoglobin&wt=json&indent=true
New (json api implementation)
http://wwwdev.ebi.ac.uk/pdbe/search/pdb/select?json={query:%20%22text:hemogl
obin%22,%20facet:%20{%20detector:%20{type:%20%27terms%27,%20field:%20%27dete
ctor%27,%20limit:%20100,%20mincount:%201,%20sort:count,%20facet:%20{%20uniqu
eCount:%20%22unique(pdb_id)%22%20}%20},%20experimental_method:%20{type:%20%2
7terms%27,%20field:%20%27experimental_method%27,%20limit:%20100,%20mincount:
%201,%20sort:count,%20facet:%20{%20uniqueCount:%20%22unique(pdb_id)%22%20}%2
0},%20deposition_year:%20{%20type:%20%27range%27,%20field:%20%27deposition_y
ear%27,%20start:%201970,%20end:%202050,%20gap:%205,%20other:%20%27between%27
,%20include%20:%20%27upper%27,%20limit:%20100,%20mincount:%201,%20sort:count
,%20facet:%20{%20uniqueCount:%20%22unique(pdb_id)%22%20}%20}%20}%20}&rows=0&
wt=json&indent=true
Am I missing something in the new facet json api query or it is a solr issue
?
Thanks and regards,
Mandar