Reputation: 181
I´m trying to find a node by a relative path:
I need to search a node which terminates in : 3265
I´m using queries like that:
SELECT * from [mgnl:news] AS t WHERE ISSAMENODE([/%/3265])
I need to know how to find a node by a relative path, thanks
Upvotes: 1
Views: 760
Reputation: 181
That´s the answer:
Select * from [mgnl:news] as t where name(t) = '3265'
This returns my node: /Application/news/3265
Thanks also.
Upvotes: 1
Reputation: 3132
You may do something like
Select * from [nt:base] where path like '%.%'
For more examples please have a look at https://wiki.magnolia-cms.com/display/WIKI/JCR+Query+Cheat+Sheet
Cheers,
Upvotes: 0