Find folders with a depth:7 but display the folder at depth:6
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Find folders with a depth:7 but display the folder at depth:6
I've used depth:7 to find all the folders that are seven deep but I cannot come up with the correct syntax to display the folders at level six that only have folders that go to level seven, highlighted in yellow on screen grab. Any help in solving this would be much appreciated. Thanks in advance.
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\" depth:7
Screen grab:
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\" depth:7
Screen grab:
Last edited by TersonWatt on Wed Nov 16, 2022 11:42 pm, edited 1 time in total.
Re: Find folders with a depth:7 but display the folder at depth:5
@void: To compliment the parents:<depth> verb, perhaps we could add a children:<depth> verb as well. Where parents: looks for objects with X levels of parents (ancestors), then children: looks for objects with X levels of children (descendants).
I know this will somewhat confuse with childcount: but I can't think of a better verbiage. The existence of parents:<level> sets the precedent. descendants:<level> or descendant-count:<level> works too. "Search for folders containing a child or grandchildren to the specified depth." I'm not sure if this necessitates *-folder and *-file options as well, or should only look for folders.
I tried forming a solution with child:*\*\* and descendant:*\*\* but neither will accept a path string only a single object name.
I know this will somewhat confuse with childcount: but I can't think of a better verbiage. The existence of parents:<level> sets the precedent. descendants:<level> or descendant-count:<level> works too. "Search for folders containing a child or grandchildren to the specified depth." I'm not sure if this necessitates *-folder and *-file options as well, or should only look for folders.
I tried forming a solution with child:*\*\* and descendant:*\*\* but neither will accept a path string only a single object name.
Last edited by raccoon on Wed Nov 16, 2022 4:45 pm, edited 1 time in total.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:5
@raccoon Does your reply mean that I'm trying to do something that is not possible with the existing functions?
Re: Find folders with a depth:7 but display the folder at depth:5
@TersonWatt: We can come up with some solutions I'm sure. Just not sure if there's anything less sloppy than using string manipulation via regex (regular expression) search and capture, and print the results to a new column for sorting and duplicate removal.
I'll let somebody else give it a crack since I may be missing an obvious feature, or a new feature of the experimental Everything 1.5 Alpha.
I'll let somebody else give it a crack since I may be missing an obvious feature, or a new feature of the experimental Everything 1.5 Alpha.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:5
@raccoon OK, thanks for your help. I thought this was something that Everything would be able to do with existing functions/syntax. If this is not the case, then using Regex commands is probably too complicated for me and rather than having you guys spent too much time on this I can sort the folders manually. But, if there is a reasonably easy solution to this I'd like to know what it is.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:5
@raccoon Thanks for mentioning the descendant function.
I was not aware of the descendant functions, so I played around with them and I think I've found the solution:
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\" descendant-folder-count:2
I was not aware of the descendant functions, so I played around with them and I think I've found the solution:
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\" descendant-folder-count:2
Re: Find folders with a depth:7 but display the folder at depth:5
Look on my suggestion for a relative Depth level.
viewtopic.php?f=12&t=12219&p=49958#p49958
As a result David made a new search function Parent+x:
Isn't this applicable to your problem ?
viewtopic.php?f=12&t=12219&p=49958#p49958
As a result David made a new search function Parent+x:
Isn't this applicable to your problem ?
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:5
@horst.epp Solved using descendant-folder-count:
I did try Parent+x: but couldn't get the result I was after.
I did try Parent+x: but couldn't get the result I was after.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:6
Thanks for the help and suggestions. Much appreciated.
Although I thought I had cracked it using descendant-folder-count: on further testing it didn't solve the issue. Trying to solve the problem with functions has fried my brain today but what I now realise is that a solution was staring at me. Sorting on the Folder Depth column brings all the folders at level seven together displaying the folder at level six* in the Name field thus allowing me to highlight them and move them to another directory.
If there is a tidier solution using functions I would still like to know.
Apologies for originally stating level 5
Although I thought I had cracked it using descendant-folder-count: on further testing it didn't solve the issue. Trying to solve the problem with functions has fried my brain today but what I now realise is that a solution was staring at me. Sorting on the Folder Depth column brings all the folders at level seven together displaying the folder at level six* in the Name field thus allowing me to highlight them and move them to another directory.
If there is a tidier solution using functions I would still like to know.
Apologies for originally stating level 5
Re: Find folders with a depth:7 but display the folder at depth:6
Sounds like a depth:6 search would have given your desired results?
Please also consider the following Everything 1.5 search:
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\*\*"
Combine with child-folder-count: to show only folders that have subfolders.
I'll consider an option to do this.
Thank you for the suggestion.
I think we also need a descendantfilelist1: search.
Please also consider the following Everything 1.5 search:
"J:\0Complete\000 DOWNLOADS\RAR MAD Magazine (001-550)\000 two folders\*\*"
Combine with child-folder-count: to show only folders that have subfolders.
Maybe child-depth: ? max-child-depth:?@void: To compliment the parents:<depth> verb, perhaps we could add a children:<depth> verb as well. Where parents: looks for objects with X levels of parents (ancestors), then children: looks for objects with X levels of children (descendants).
I'll consider an option to do this.
Thank you for the suggestion.
I think we also need a descendantfilelist1: search.
Re: Find folders with a depth:7 but display the folder at depth:6
I think what the OP was asking for, by analogy, is "How can I search all my movies folders for those that have .\Extras\Subs\ or .\Samples\pics\ or any other set of folders that goes 2-deep or more." I assume he's trying to find and flatten them.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:6
@void & &raccoon Thank you and the others who have replied to my query.
I am so embarrassed but have learnt a valuable lesson when troubleshooting.
My screen grab is displaying a better solution for what I wanted to do with the end results i.e. depth:7 and @void's suggestion of depth:6 would have given me what I was asking for.
The lesson I've learnt is that I should have created a sensibly named folder structure and used that to try the functions. The results I was seeing from the original named folder structure caused my confusion.
Once again, thanks for your help which made me see it was my confusion over the name of the folders rather than the functions I was trying.
I am so embarrassed but have learnt a valuable lesson when troubleshooting.
My screen grab is displaying a better solution for what I wanted to do with the end results i.e. depth:7 and @void's suggestion of depth:6 would have given me what I was asking for.
The lesson I've learnt is that I should have created a sensibly named folder structure and used that to try the functions. The results I was seeing from the original named folder structure caused my confusion.
Once again, thanks for your help which made me see it was my confusion over the name of the folders rather than the functions I was trying.
Re: Find folders with a depth:7 but display the folder at depth:6
Everything 1.5.0.1330a adds the following search functions:
Usage example:
depth:6 max-child-depth:>=2
depth:6 descendantfilelist1:
Hold down Ctrl and click the descendantfilelist1: text to set the file list slot.
Usage example:
depth:6 max-child-depth:>=2
depth:6 descendantfilelist1:
Hold down Ctrl and click the descendantfilelist1: text to set the file list slot.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:6
Thanks for the update. I haven't delved into filelists yet but I can see how the max-child-depth: function will be useful.
Rather than start a new thread, I hope it's OK to use this thread to ask for help with another similar task.
I'd like to display/search for folders at depth 4 if there is a certain type of file at level 4 and lower levels e.g 5, 6, 7 etc. Once again, I'm struggling with the syntax. In this case, I'm not even sure which functions to use. I can use child:*.flac to get a list of the folders where the flac files are located and, if they are at depth 4, I can move the folders. However, I would also like to move the folders at level 4 if they have flac files at lower depths.
Any help will be much appreciated.
Rather than start a new thread, I hope it's OK to use this thread to ask for help with another similar task.
I'd like to display/search for folders at depth 4 if there is a certain type of file at level 4 and lower levels e.g 5, 6, 7 etc. Once again, I'm struggling with the syntax. In this case, I'm not even sure which functions to use. I can use child:*.flac to get a list of the folders where the flac files are located and, if they are at depth 4, I can move the folders. However, I would also like to move the folders at level 4 if they have flac files at lower depths.
Any help will be much appreciated.
Re: Find folders with a depth:7 but display the folder at depth:6
Please try the following search:
descendant:*.flac depth:4
descendant: searches children and grandchildren (subfolders)
child: searches direct children only.
descendant:*.flac depth:4
descendant: searches children and grandchildren (subfolders)
child: searches direct children only.
-
- Posts: 19
- Joined: Wed Oct 26, 2022 7:21 am
Re: Find folders with a depth:7 but display the folder at depth:6
@void Thanks the swift response and the solution to my query. Much appreciated. Cheers