Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

How to Search Excerpt from QueryBuilder?

Avatar

Avatar
Validate 1
Level 1
熊超
Level 1

Likes

0 likes

Total Posts

3 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
熊超
Level 1

Likes

0 likes

Total Posts

3 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile
熊超
Level 1

25-03-2019

I want search like this;
1718919_pastedImage_0.png

I try test like

map.put("path", "/content"));

map.put("fulltext","geo");

Query query = queryBuilder.createQuery(PredicateGroup.create(params), session);

SearchResult result= query.getResult();

for (Hit hit : result.getHits()) {

   Map<String, String> excerpts = hit .getExcerpts();
}

but excerpts is null;

what should I do?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Give back 300
MVP
Gaurav-Behl
MVP

Likes

243 likes

Total Posts

1,145 posts

Correct Reply

281 solutions
Top badges earned
Give back 300
Give Back 50
Give Back 5
Give Back 3
Give Back 25
View profile

Avatar
Give back 300
MVP
Gaurav-Behl
MVP

Likes

243 likes

Total Posts

1,145 posts

Correct Reply

281 solutions
Top badges earned
Give back 300
Give Back 50
Give Back 5
Give Back 3
Give Back 25
View profile
Gaurav-Behl
MVP

26-03-2019

It is picking up excerpts otherwise it wouldn't highlight "geo" in the results. this is something else

check  aem 6.2 querybuilder api not returning results  or debug the code

Adobe Experience Manager Help | Creating a HTML Template Language component that uses the AEM QueryB...

Answers (0)