> Hi,
> I am looking for a way to use payloads in my search
> application. Indexing
> data with payloads into Solr is pretty straightforward.
> However using the
> payloads during search time is a bit confusing. Can anyone
> point me in the
> right direction to enable payloads on a *PhraseQuery*. I
> looked at the
> following resources and got payload on a TermQuery
> working.
> 
>    1.
>    http://www.lucidimagination.com/blog/2009/08/05/getting-started-with-payloads/
>    2. http://www.mail-archive.com/solr-user@lucene.apache.org/msg24863.html
>    3. There is also a jira issue (SOLR-1485)
> that gives a patch for using
>    Payload.
>    4. Lucene-In-Action
> 
> I am guessing that I should return a payload version of
> PhraseQuery in
> QueryParser's (package
> org.apache.lucene.queryParser.queryParser.java)
> newPhraseQuery function. If yes, what type should this
> query be?

Yes. PayloadNearQuery [1]

[1]http://lucene.apache.org/java/3_0_0/api/core/org/apache/lucene/search/payloads/PayloadNearQuery.html



Reply via email to