lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Markus Jelsma <>
Subject RE: Autosuggest on PART of cityname
Date Thu, 19 Aug 2010 14:52:38 GMT
You need a new analyzed field with the EdgeNGramTokenizer or you can try facet.prefix for this
to work. To retrieve the number of locations for that city, just use the results from the
faceting engine as usual.


I'm unsure which approach is actually faster but i'd guess using the EdgeNGramTokenizer is
faster, but also takes up more disk space. Using the faceting engine will not take more disk
-----Original message-----
From: PeterKerk <>
Sent: Thu 19-08-2010 16:46
Subject: Autosuggest on PART of cityname

I want to have a Google-like autosuggest function on citynames. So when user
types some characters I want to show cities that match those characters but
ALSO the amount of locations that are in that city.

Now with Solr I now have the parameter:

But the result doesnt show the city Boston. So the fq parameter now seems to
be an exact match, where I want it to be a partial match as well, more like
this in SQL: WHERE title LIKE '<value>%'

How can I do this?

View this message in context:
Sent from the Solr - User mailing list archive at

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message