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 Ahson Iqbal <mi...@yahoo.com> on 2011/09/13 07:27:02 UTC
question about Field Collapsing/ grouping
Hi
Is it possible to get number of groups that matched with specified query.
like let say there are three fields in index
DocumentID
Content
Industry
and now i want to query as +(Content:is Content:the)
group=true&group.field=industry
now is it possible to get how many industries matched with specified query.
Please help.
Regards
Ahsan
Re: question about Field Collapsing/ grouping
Posted by Jayendra Patil <ja...@gmail.com>.
Hi Ahson,
http://wiki.apache.org/solr/FieldCollapsing
group.ngroups seems to be added as an parameter, so you may not be
needed to apply any patches.
Solr 3.3 had released the grouping feature with it, so I presume it
should already be included in it.
Regards,
Jayendra
On Wed, Sep 14, 2011 at 4:22 AM, Ahson Iqbal <mi...@yahoo.com> wrote:
> Hi Jayendra
>
> Thanks a lot for your response, now i have two questions one that to get the count of groups is it must to apply the specified patch, if so can you help me a little how i can apply that patch in steps as i am new to solr/java.
>
> Regards
> Ahsan
>
>
>
> ----- Original Message -----
> From: Jayendra Patil <ja...@gmail.com>
> To: solr-user@lucene.apache.org; Ahson Iqbal <mi...@yahoo.com>
> Cc:
> Sent: Tuesday, September 13, 2011 10:55 AM
> Subject: Re: question about Field Collapsing/ grouping
>
> The time we implemented the feature, there was no straight forward solution.
>
> What we did is to facet on the grouped by field and counting the facets.
> This would give you the distinct count for the groups.
>
> You may also want to check the Patch @
> https://issues.apache.org/jira/browse/SOLR-2242, which will return the
> facet counts and you need to count it by yourself.
>
> Regards,
> Jayendra
>
> On Tue, Sep 13, 2011 at 1:27 AM, Ahson Iqbal <mi...@yahoo.com> wrote:
>> Hi
>>
>> Is it possible to get number of groups that matched with specified query.
>>
>> like let say there are three fields in index
>>
>> DocumentID
>> Content
>> Industry
>>
>>
>> and now i want to query as +(Content:is Content:the)
>> group=true&group.field=industry
>>
>> now is it possible to get how many industries matched with specified query.
>>
>> Please help.
>>
>> Regards
>> Ahsan
>>
>
Re: question about Field Collapsing/ grouping
Posted by Ahson Iqbal <mi...@yahoo.com>.
Hi Jayendra
Thanks a lot for your response, now i have two questions one that to get the count of groups is it must to apply the specified patch, if so can you help me a little how i can apply that patch in steps as i am new to solr/java.
Regards
Ahsan
----- Original Message -----
From: Jayendra Patil <ja...@gmail.com>
To: solr-user@lucene.apache.org; Ahson Iqbal <mi...@yahoo.com>
Cc:
Sent: Tuesday, September 13, 2011 10:55 AM
Subject: Re: question about Field Collapsing/ grouping
The time we implemented the feature, there was no straight forward solution.
What we did is to facet on the grouped by field and counting the facets.
This would give you the distinct count for the groups.
You may also want to check the Patch @
https://issues.apache.org/jira/browse/SOLR-2242, which will return the
facet counts and you need to count it by yourself.
Regards,
Jayendra
On Tue, Sep 13, 2011 at 1:27 AM, Ahson Iqbal <mi...@yahoo.com> wrote:
> Hi
>
> Is it possible to get number of groups that matched with specified query.
>
> like let say there are three fields in index
>
> DocumentID
> Content
> Industry
>
>
> and now i want to query as +(Content:is Content:the)
> group=true&group.field=industry
>
> now is it possible to get how many industries matched with specified query.
>
> Please help.
>
> Regards
> Ahsan
>
Re: question about Field Collapsing/ grouping
Posted by Jayendra Patil <ja...@gmail.com>.
yup .. seems the group count feature is included now, as mentioned by Klein.
Regards,
Jayendra
On Tue, Sep 13, 2011 at 8:27 AM, O. Klein <kl...@octoweb.nl> wrote:
> Isn't that what the parameter group.ngroups=true is for?
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/question-about-Field-Collapsing-grouping-tp3331821p3332471.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
Re: question about Field Collapsing/ grouping
Posted by "O. Klein" <kl...@octoweb.nl>.
Isn't that what the parameter group.ngroups=true is for?
--
View this message in context: http://lucene.472066.n3.nabble.com/question-about-Field-Collapsing-grouping-tp3331821p3332471.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: question about Field Collapsing/ grouping
Posted by Jayendra Patil <ja...@gmail.com>.
The time we implemented the feature, there was no straight forward solution.
What we did is to facet on the grouped by field and counting the facets.
This would give you the distinct count for the groups.
You may also want to check the Patch @
https://issues.apache.org/jira/browse/SOLR-2242, which will return the
facet counts and you need to count it by yourself.
Regards,
Jayendra
On Tue, Sep 13, 2011 at 1:27 AM, Ahson Iqbal <mi...@yahoo.com> wrote:
> Hi
>
> Is it possible to get number of groups that matched with specified query.
>
> like let say there are three fields in index
>
> DocumentID
> Content
> Industry
>
>
> and now i want to query as +(Content:is Content:the)
> group=true&group.field=industry
>
> now is it possible to get how many industries matched with specified query.
>
> Please help.
>
> Regards
> Ahsan
>