How to exclude search results based on a sub path - Path LIKE | Community
Skip to main content
Level 2
April 11, 2016
Solved

How to exclude search results based on a sub path - Path LIKE

  • April 11, 2016
  • 3 replies
  • 2505 views

Hello Friends,

I want to get all dam assets but not subassets. Subassets are also of same type as assets i.e. dam:Asset.

Is there a way to have a wild card (or LIKE operation) in case of the path predicate?

path=/content/dam
type=dam:Asset
p.limit=-1

group.p.not=true
group.1_path.operation=like
group.1_path=%subassets%

 

Thanks

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 r.l.sharma

@Tuhin

Thanks for your response. No specific property on subassets. 

We were able to do that anyways....here's how we did it:

property=../../jcr:content/jcr:primaryType
property.operation=unequals
property.value=dam:AssetContent

If a dam:Asset node has its parent as dam:AssetContent, then its a subasset.

3 replies

Tuhin_Ghosh
Level 8
April 14, 2016

Is there any certain property present in your sub-assets?

r.l.sharmaAuthorAccepted solution
Level 2
April 14, 2016

@Tuhin

Thanks for your response. No specific property on subassets. 

We were able to do that anyways....here's how we did it:

property=../../jcr:content/jcr:primaryType
property.operation=unequals
property.value=dam:AssetContent

If a dam:Asset node has its parent as dam:AssetContent, then its a subasset.

Tuhin_Ghosh
Level 8
April 14, 2016

RS SH wrote...

@Tuhin

Thanks for your response. No specific property on subassets. 

We were able to do that anyways....here's how we did it:

property=../../jcr:content/jcr:primaryType
property.operation=unequals
property.value=dam:AssetContent

If a dam:Asset node has its parent as dam:AssetContent, then its a subasset.

 

Thats why I wanted to know the type. Cheers.