SID-00988: Displaying recently changed topic/children/grandchildren?
| Status: |
Answered |
TWiki version: |
|
Perl version: |
|
| Category: |
CategorySearch |
Server OS: |
|
Last update: |
15 years ago |
Is there a way to display a list of all recently changed topics within a tree of topic, its children, and all grandchildren, etc?
Right now I am using:
%SEARCH{"parent.name = 'DesignHub'" web="%WEB%" type="query" order="modified" reverse="on" nosearch="on" noheader="on" limit="50"}%
But I only get immediate children of 'DesignHub'. Want all the descendants.
Thanks for any info.
--
DavidHatch - 2010-10-01
Discussion and Answer
Here is an untested search to get first level and second level:
"(parent.name = 'DesignHub') OR (parent.name/(parent.name = 'DesignHub'))"
Details in
QuerySearch.
--
PeterThoeny - 2010-10-01
Fantastic!! Thanks so much. And by extension you could add a 3rd level by?
"(parent.name = 'DesignHub') OR (parent.name/(parent.name = 'DesignHub')) OR (parent.name/(parent.name/(parent.name = 'DesignHub'))) "
And could you keep doing this? I may have up to 6 levels. Is this a decent approach or is there a wildcard way of achieving the same thing?
Again, thanks so much!
--
DavidHatch - 2010-10-01
Basically yes on adding levels. There is no wild card. Keep in mind that nested searches will be slow.
--
PeterThoeny - 2010-10-01
ok thanks
--
DavidHatch - 2010-10-01
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.