Force OAK index used | Community
Skip to main content
Level 3
November 3, 2015
Solved

Force OAK index used

In AEM 6.0 using OAK, is it possible when writing a XPATH query to force what index is being used rather that letting the system determine which it thinks is the fastest evaluated index.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
joerghoh
joerghohAccepted solution
Employee
November 3, 2015

Hi,

it is not possible. You can use EXPLAIN to check why Oak uses a certain index.

kind regards,
Jörg

6 replies

Employee
November 4, 2015

Hi,

can you take a screenshot of the output when you run the query with the "Explain Query" page, similar to [1].

Regards,

Opkar

[1] https://adobe-consulting-services.github.io/acs-aem-tools/images/explain-query/results.png

Translate
Lokesh_Shivalingaiah
Level 10
November 4, 2015

It should not be the case. However can you share your query ?

Translate
Level 3
November 4, 2015

I am already using the explain tool. I have observed that it doesn't always pick the fastest - when lucene index is 510.0, cq:tag index is 310.0, it still prefers to use the slowest - traverse.

Translate
kautuk_sahni
Employee
November 4, 2015

Hi

Could you please share the use-case for the community.

 

Thanks and Regards

Kautuk Sahni

Translate
Kautuk Sahni
Lokesh_Shivalingaiah
Level 10
November 3, 2015

when it already uses the fastest index, any reason why you would like to override it ??

Translate
joerghoh
joerghohAccepted solution
Employee
November 3, 2015

Hi,

it is not possible. You can use EXPLAIN to check why Oak uses a certain index.

kind regards,
Jörg

Translate