I have a field: specialties that is multiValued.

It indicates the doctor's specialties: cardiologist, internist, etc.

When someone does a search: "Cardiologist", I use
q=cardiologist&defType=dismax&qf=specialties&facet=true&facet.field=specialt
ies

What I want to come out in the facet is the Cardiologist (since it matches
exactly) and the number that matches: 700.
I don't want to see the other values that are not Cardiologist.

Now I see:

Cardiologist: 700
Internist: 45
Family Doctor: 20

This means that several Cardiologist's are also internists and family
doctors. When it matches exactly, I don't want to see Internists, Family
Doctors. How do I send a query to Solr with a condition.
Facet.query=specialties:Cardiologist&facet.field=specialties

Then if the query returns something use it, otherwise use the field one?

Other ideas?



Reply via email to