AEM - Search by content from text based document question | Community
Skip to main content
New Participant
November 11, 2024

AEM - Search by content from text based document question

  • November 11, 2024
  • 2 replies
  • 871 views

Hello All

 

I have two different documents (one.txt and two.txt) in same folder with same text. For example, 'Technical details page'

And Documents are re-indexed.

 

Backend search query is

fulltext = Technical details page

p.offset=0

p.limit=-1

type=dam:Asset

 

when searched for results. I'm getting only one document. One.txt

 

And when remove type=dam:Asset from above query. Many results are returned and has my two documents.

 

First Query Search Results

1. /content/dam/one.text

 

Second Query Search Results

1. /content/dam/one.txt

2. /content/dam/one.txt/jcr:content/renditions/page/jcr:content/par/text/text-16

3. /content/dam/two.txt

4. /content/dam/two.txt/jcr:content/renditions/page/jcr:content/par/text/text-10

 

The difference between first search results and second search (removed type=dam:Asset) results is that second query checked inside dam:Asset and returned my results.

 

Questions is: How the first query is able to return one.txt ? why did it not give two.txt in results?

How to fix this.?

 

Both docs have been indexed

 

Thanks,

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

2 replies

Manu_Mathew_
New Participant
November 22, 2024

@girishb83316758 where you able to reproduce the issue, can you send the full query both with results in screenshots?

kaikubad
New Participant
November 11, 2024

Hi,

 

path=/content/dam/{path}

fulltext = Technical details page

p.limit=-1

type=dam:Asset

 

this should return all resources type of dam:Asset under the path specified.

Can check examples here. https://github.com/paulrohrbeck/aem-links/blob/master/querybuilder_cheatsheet.md

 

New Participant
November 11, 2024

But how first query returned the results?