Mailing List Archive

Multi-Value query test
How to test if a value in a multi-value field matches a specific query?

Example of the problem:

I've created a query to return all documents of some specific authors. The
authors field contains multi-value sorted set.
When showing the result, I want to show only the name of the authors
specified on the query, even if the document has more authors.
Multi-Value Query Test [ In reply to ]
How to test if a value in a multi-value field matches a specific query?

Example of the problem:

I've created a query to return all documents of some specific authors. The
authors field contains multi-value sorted set.
When showing the result, I want to show only the name of the authors
specified on the query, even if the document has more authors.
Re: Multi-Value query test [ In reply to ]
Maybe I misunderstand the problem, but why don't you decouple showing
the results from the results of the query?

Am 23.06.22 um 14:03 schrieb Patrick Bernardina:
> How to test if a value in a multi-value field matches a specific query?
>
> Example of the problem:
>
> I've created a query to return all documents of some specific authors. The
> authors field contains multi-value sorted set.
> When showing the result, I want to show only the name of the authors
> specified on the query, even if the document has more authors.
>


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: Multi-Value query test [ In reply to ]
Let me clarify:
Example query: "(author:Patrick author:Michael) && type:pdf"
Example result: 2 items: Doc1 with authors "Patrick, Adalberto" and Doc2
with authors "Patrick, Michael, Elias"

I want to show the 2 items, but when I show the authors, I only want to
show the authors that are in the query also:
Doc1 - Patrick
Doc1 - Patrick, Michael

So, I need to test each author value if is valid for the same query used
for the resultSet.



Il giorno gio 23 giu 2022 alle ore 08:08 Michael Wechner <
michael.wechner@wyona.com> ha scritto:

> Maybe I misunderstand the problem, but why don't you decouple showing
> the results from the results of the query?
>
> Am 23.06.22 um 14:03 schrieb Patrick Bernardina:
> > How to test if a value in a multi-value field matches a specific query?
> >
> > Example of the problem:
> >
> > I've created a query to return all documents of some specific authors.
> The
> > authors field contains multi-value sorted set.
> > When showing the result, I want to show only the name of the authors
> > specified on the query, even if the document has more authors.
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>