Marvin created OAK-11949:
----------------------------
Summary: Union queries should still order by score
Key: OAK-11949
URL: https://issues.apache.org/jira/browse/OAK-11949
Project: Jackrabbit Oak
Issue Type: Story
Components: indexing
Reporter: Marvin
Right now, union queries do not sort by score it seems. Explicitly ordering
(using a hack) seems to change the result order. But we need to do this
automatically.
Alternatively, we should not make a union query, but provide the filter to
elasticsearch.
There is a workaround, but performance is very bad if there are many results in
one (or more) of the union parts:
{noformat}
/jcr:root/content/dam//element(*, dam:Asset)[jcr:contains(., 'hello') or
jcr:contains(., 'world')] order by fn:upper-case(@jcr:score) descending
type=dam:Asset
path=/content/dam
fulltext=?{}?people
orderby=@jcr:score
orderby.case=ignore
orderby.sort=desc
p.guessTotal=100
{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)