Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events
SOLVED

Query to search All keywords attached to the page

Avatar

Community Advisor

Hi All, We've added one property called "jcr:keywords" in page properties dialog. We will be adding keywords for each page. These keywords will be used for search specifically for 'search suggestions'.  Now, we need to write query to show all keywords in search suggestions. Also, I've followed [1] and created Lucene-suggest index node. [1]: http://jackrabbit.apache.org/oak/docs/query/lucene.html Quick help would be more appreciated.

1 Accepted Solution

Avatar

Correct answer by
Employee

Hi Sivaprasad,

You want help designing the query to search for keywords? You can use QueryBuilderAPI documentation to design the query. What query will be eventually used will depend on your use case and node structure.

View solution in original post

3 Replies

Avatar

Level 10

Are you using QueryBuilder API to search?

Avatar

Community Advisor

Yes Smacdonald. I'm using QueryBuilder API. Also, please let me know if there is any other better approach.

Avatar

Correct answer by
Employee

Hi Sivaprasad,

You want help designing the query to search for keywords? You can use QueryBuilderAPI documentation to design the query. What query will be eventually used will depend on your use case and node structure.