You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by szzoli <re...@freemail.hu> on 2016/09/29 14:26:27 UTC
How can I get the term positions from a query?
Hi,
How can I get the term positions from a query? It was in the docs, that it
must be ceated at indexing time. But how?
And later, how can I retieve them, for each term? Is it possible for each
Query?
--
View this message in context: http://lucene.472066.n3.nabble.com/How-can-I-get-the-term-positions-from-a-query-tp4298640.html
Sent from the Lucene - Java Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: How can I get the term positions from a query?
Posted by Dawid Weiss <da...@gmail.com>.
There are multiple Highlighter implementations for this purpose. Check
them out -- I'm sure one of them will suit your needs. In fact,
there's a new highlighter implemented very recently! Check out this
JIRA issue:
https://issues.apache.org/jira/browse/LUCENE-7438
Dawid
On Fri, Sep 30, 2016 at 8:46 AM, szzoli <re...@freemail.hu> wrote:
> I would like to show the results of a Query, including hits/document and then
> the position of the term found.
> What makes it more complicated, is, that I have to use a PhaseQuery, to
> search for a list of terms.
>
>
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/How-can-I-get-the-term-positions-from-a-query-tp4298640p4298785.html
> Sent from the Lucene - Java Users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: How can I get the term positions from a query?
Posted by szzoli <re...@freemail.hu>.
I would like to show the results of a Query, including hits/document and then
the position of the term found.
What makes it more complicated, is, that I have to use a PhaseQuery, to
search for a list of terms.
--
View this message in context: http://lucene.472066.n3.nabble.com/How-can-I-get-the-term-positions-from-a-query-tp4298640p4298785.html
Sent from the Lucene - Java Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: How can I get the term positions from a query?
Posted by Adrien Grand <jp...@gmail.com>.
There are multiple answers to this question depending on what you are
actually trying to do, can you tell us more about the use-case?
Le jeu. 29 sept. 2016 à 16:26, szzoli <re...@freemail.hu> a écrit :
> Hi,
>
> How can I get the term positions from a query? It was in the docs, that it
> must be ceated at indexing time. But how?
> And later, how can I retieve them, for each term? Is it possible for each
> Query?
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/How-can-I-get-the-term-positions-from-a-query-tp4298640.html
> Sent from the Lucene - Java Users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>