Ok I think I get this. I think this can be achieved if one could
specify a filter inside a group and only documents that pass the
filter get grouped. For example only group documents with the value
image for the mimetype field. This filter should be specified per
group command. Maybe we should open an issue for this?

Martijn

On 1 November 2011 19:58, entdeveloper <cameron.develo...@gmail.com> wrote:
>
> Martijn v Groningen-2 wrote:
>>
>> When using the group.field option values must be the same otherwise
>> they don't get grouped together. Maybe fuzzy grouping would be nice.
>> Grouping videos and images based on mimetype should be easy, right?
>> Videos have a mimetype that start with video/ and images have a
>> mimetype that start with image/. Storing the mime type's subtype and
>> type in separate fields and group on the type field would do the job.
>> Off course you need to know the mimetype during indexing, but
>> solutions like Apache Tika can do that for you.
>
> Not necessarily interested in grouping by mimetype (that's an analysis
> issue). I simply used videos and images as an example.
>
> I'm not sure what you mean by fuzzy grouping. But my goal is to have
> collapse be more selective somehow on what gets grouped. As a more specific
> example, I have a field called 'type', with the following possible field
> values:
>
> Type
> ------
> image
> video
> webpage
>
>
> Basically I want to be able to collapse all the images into a single result
> so that they don't fill up the first page of the results. This is not
> possible with the current grouping implementation because if you call
> group.field=type, it'll group everything. I do not want to collapse videos
> or webpages, only images.
>
> I've attached a screenshot of google's srp to help explain what I mean.
>
> http://lucene.472066.n3.nabble.com/file/n3471548/Screen_Shot_2011-11-01_at_11.52.04_AM.png
>
> Hopefully that makes more sense. If it's still not clear I can email you
> privately.
>
> --
> View this message in context: 
> http://lucene.472066.n3.nabble.com/Selective-Result-Grouping-tp3391538p3471548.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>



-- 
Met vriendelijke groet,

Martijn van Groningen

Reply via email to