ntBaseLucene index | Community
Skip to main content
Level 4
Jul 14, 2017 3:26 PM UTC

ntBaseLucene index

Hi,

We are using search by fileName.

Example:

SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE('/etc/project/test') AND NAME() LIKE '%\_us'

Explain query display WARNINGThis query has characteristics that may cause performance issues when executed against large repositories.

I've adjusted ntBaseLucene index (Add indexNodeName= true on /oak:index/ntBaseLucene/indexRules/nt:base node.Using Oak Utilities : Index Definition Generator.

After such change:

+ Warning disappear and query is much faster

- Query stopping return results with escaping

Example:

SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE('/etc/project/test') AND NAME() LIKE '%\_us'

Return: No results.

SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE('/etc/project/test') AND NAME() LIKE '%_us'

Return: /etc/project/test/en_us

Does anyone know what's wrong here?

We are using AEM6.1 with SP1. OAK version 1.2.11

Thanks,

Alex

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

4 replies

zeeshanKhan0786
Level 5
Jul 14, 2017 3:52 PM UTC

This Link will be helpful. I am seeing there is a problem in your Query to Escape.

Chapter 27. JCR Query Usecases

Translate
Level 4
Jul 16, 2017 4:51 PM UTC

The problem is that before changes in oak index both queries were returned /etc/project/test/en_us

Translate
zeeshanKhan0786
Level 5
Jul 17, 2017 6:01 AM UTC

Hi Alex,

Did you change the query and tried it.

Check this thread Issue with oak index selection and ordered properties

Translate