lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Koji Sekiguchi <k...@r.email.ne.jp>
Subject Re: Using hl.regex.pattern to print complete lines
Date Fri, 09 Jul 2010 00:56:52 GMT
(10/07/09 9:30), Peter Spam wrote:
> Thanks for the note, Koji.  However, hl.fragsize=0 seems to return the entire document,
rather than just one single line.
>
> Here's what I tried (what I previously had was commented out):
>
> regexv = "^.*$"
> thequery = '/solr/select?facet=true&facet.limit=10&fl=id,score,filename&tv=true&timeAllowed=3000&facet.field=filename&qt=tvrh&wt=ruby'
+ (p['fq'].empty? ? '' : ('&fq='+p['fq'].to_s) ) + '&q=' + CGI::escape(p['q'].to_s)
+ '&rows=' + p['rows'].to_s + "&hl=true&hl.snippets=1&hl.fragsize=0" #&hl.regex.slop=.8&hl.fragsize=200&hl.fragmenter=regex&hl.regex.pattern="
+ CGI::escape(regexv)
>
> Thanks for your help.
>
>
> -Peter
>
>    
Peter,

Are you sure using GapFragmenter when you set fragsize to 0?

I've never tried regex fragmenter...

If you can use the latest branch_3x or trunk, hl.fragListBuilder=single
is available that is for getting entire field contents with search terms
highlighted. To use it, set hl.useFastVectorHighlighter to true.

Koji

-- 
http://www.rondhuit.com/en/


Mime
View raw message