Querybuilder search for tags with Title value only | Community
Skip to main content
Level 2
December 1, 2023
Solved

Querybuilder search for tags with Title value only

  • December 1, 2023
  • 2 replies
  • 1182 views

Hi, may I know if it is possible if we can search for tags with only giving its title value?

For example, I want to search the tag with title value of "Manager" then I will get its path thru the result of querybuilder.

Thank you!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by lukasz-m

Hi @aemstarternewbie,

This is possible, please check below query:

path=/content/cq:tags type=cq:Tag 1_property=jcr:title 1_property.value=Manager

2 replies

lukasz-m
Community Advisor
lukasz-mCommunity AdvisorAccepted solution
Community Advisor
December 1, 2023

Hi @aemstarternewbie,

This is possible, please check below query:

path=/content/cq:tags type=cq:Tag 1_property=jcr:title 1_property.value=Manager
partyush
Community Advisor
Community Advisor
December 1, 2023

Hi @aemstarternewbie  , 

 

Yes I agree with @lukasz-m  and has provides good information about the same,

 

In Addition to his context, I would like to add more detail so that it can become easier to you to understand. For querying tags based on their title value using AEM Query Builder, you can structure the query like this:

 

path=/etc/tags

type=cq:Tag

1_property=jcr:content/jcr:title

1_property.value=Manager

 

Here's the breakdown of this query:

  • path=/etc/tags: Specifies the starting path for the search. Adjust it based on your tag structure.
  • type=cq:Tag: Specifies that you are searching for tags.
  • 1_property=jcr:content/jcr:title: Filters based on the jcr:title property of the tag.
  • 1_property.value=Manager: Specifies the value you are searching for (replace "Manager" with your desired title).

This query will return the paths of tags where the title matches "Manager." Make sure to test and adapt it according to your AEM instance's specific tag structure.