Deepti
Deepti

Reputation: 11

How to form select distinct(parameter) query in Apache Solr

example :

select distinct(city) from employee_details where name="JOHN";

How to form select distinct(parameter) query in Apache Solr ?

Upvotes: 0

Views: 229

Answers (1)

Sanjay Dutt
Sanjay Dutt

Reputation: 2222

You can use facets to produce distinct values

q=name:JOHN&facet=true&facet.field=city&rows=0

try to run above query

Upvotes: 2

Related Questions