[Xapian-discuss] Text snippets

Peter Karman peter at peknet.com
Thu Jan 14 22:33:05 GMT 2010


Shripad Bodas wrote on 1/14/10 3:40 PM:
> Hi,
> 
> The problem I am facing using Search::Tools is xapian treats query
> string in terms eg. if the query is "universities" xapian may have a
> corresponding term for this query as "universit" and while searching
> it uses this term rather than "universities". Now if one of the page
> has "university" in its text I want to highlight that as well. But
> since the actual query is "universities" Search::Tools doesnt
> highlight this word though xapian::search shows this page in the
> result.
> Now in my overall architecture I can supply this term list (i.e.
> universit) to the perl script but is there any way that Search::Tool
> will match half-word but highlight full-word?
> 

Search::Tools::QueryParser->new() takes a stemmer argument, documented here:

http://search.cpan.org/dist/Search-Tools/lib/Search/Tools/QueryParser.pm#stemmer

-- 
Peter Karman  .  http://peknet.com/  .  peter at peknet.com



More information about the Xapian-discuss mailing list