Retrieving distinct documents from Solr -
i've had hard time explaining , finding need please put self in shoes moment.
my requirement comes relational database background. may using solr wasn't designed do, or may can need, still need confirm that. can assist me.
after indexing numerous documents solr. need retrieve distinct documents based on filter. think retrieving distinct rows while applying condition.
for example, in relational database, may have following columns
(country) (city) (whatever) egypt cairo hospitals egypt alex schools egypt mansoura hospitals egypt cairo schools
if perform query: select distinct country, city mytable
i should following rows
(country) (city) egypt alex egypt mansoura egypt cairo
now after indexing original table (select * mytable
), how can achieve same output solr ? how can retrieve documents saying need these documents distinct based on fields ? need apply not null filter specific field.
i don't need statistics of kind, need documents.
i hope clear enough. thank time.
this achievable field collapsing grouping multiple fields, unfortunately 1 field supported right now. there open issue, check out.
Comments
Post a Comment