lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Md. Mazharul Anwar" <mazha...@seekasia.com>
Subject Global pagination on grouped result doesn't work.
Date Mon, 17 Aug 2015 11:14:45 GMT
Hello,


My Goal: Search solr and group the result based on a field , paginate through the grouped
result.

The query I used: group=true&group.field=customer_company_name&group.ngroups=true


I get a result set of:


{

  *
responseHeader:
{
     *
status: 0,
     *
QTime: 20,
     *
params:
{
        *
group.ngroups: "true",
        *
indent: "true",
        *
q: "customer_company_name_lc:com*",
        *
group.field: "customer_company_name",
        *
group: "true",
        *
wt: "json"
}
},
  *
grouped:
{
     *
customer_company_name:
{
        *
matches: 565,
        *
ngroups: 352,
        *
groups:
[
        *
{ ...








So I presume I can paginate through the groups by using &start=300&rows=60 ? Based
on the total ngroups are 352, I should get back a json with 52 docs. However, when I do that
myresult seems to be returning with 0 docs. An empty doc block. Like this:
{

  *
responseHeader:
{
     *
status: 0,
     *
QTime: 9,
     *
params:
{
        *
group.ngroups: "true",
        *
indent: "true",
        *
start: "300",
        *
q: "customer_company_name_lc:com*",
        *
group.field: "customer_company_name",
        *
group: "true",
        *
wt: "json",
        *
rows: "2"
}
},
  *
grouped:
{
     *
customer_company_name:
{
        *
matches: 565,
        *
ngroups: 352,
        *
groups: [ ]
}
}

}


May I know what I am doing wrong or should I look at the problem from a different point of
view ?

Thanks.
Maz

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message