: One more question about using wildcard. I found if wildcard is used in
: the query, the highlight elements only shows unique id, it won't display

: <lst name="highlighting">
:  <lst name="id1">
:   <arr name="TITLE">
:     <str><em>Consult</em>ant</str>

your description of the problem doesn't seem to match what you've pasted
... it looks like it's highlighting just the prefix from the query.

You're using Solr 1.1 right?

Unfortunately, i think you are damned if you do, damned if you don't ...
in Solr 1.1, highlighting used the info from the raw query to do
highlighting, hence in your query for consult* it would highlight
the Consult part of Consultant even though the prefix query was matchign
the whole word.  In the trunk (soon to be Solr 1.2) Mike fixed that so the
query is "rewritten" to it's expanded form before highlighting is done ...
this works great for true wild card queries (ie: cons*t* or cons?lt*) but
for prefix queries Solr has an optimization ofr Prefix queries (ie:
consult*) to reduce the likely hood of Solr crashing if the prefix matches
a lot of terms ... unfortunately this breaks highlighting of prefix
queries, and no one has implemented a solution yet...

https://issues.apache.org/jira/browse/SOLR-195




-Hoss

Reply via email to