How to search only 1 subdir deep?
How to search only 1 subdir deep?
So I found very little ala google on this, tried what I found - but couldnt seem to get it right.
I have a directory full of folders. Said folders all include a file in their root that shares the same name. I need to grab those files all together but the problem is, some of those folders also have a file with the same name nested deeper which I want to omit. I only need the file from the root of first subdirectory (folders) within the directory im searching.
Hoping im explaining this adequately. A checkbox to omit subdirectories with a box to enter a depth number would go a long ways for those of us less proficient in this area
and thanks to the author of the program. facepalming for waiting so long to get on board. the straw that broke this camels back was windows further neutering of the explorer search with the newest update. its dead to me now ;p
I have a directory full of folders. Said folders all include a file in their root that shares the same name. I need to grab those files all together but the problem is, some of those folders also have a file with the same name nested deeper which I want to omit. I only need the file from the root of first subdirectory (folders) within the directory im searching.
Hoping im explaining this adequately. A checkbox to omit subdirectories with a box to enter a depth number would go a long ways for those of us less proficient in this area
and thanks to the author of the program. facepalming for waiting so long to get on board. the straw that broke this camels back was windows further neutering of the explorer search with the newest update. its dead to me now ;p
Re: How to search only 1 subdir deep?
parents:
parents:4 klep
finds 15-Kleptomania.mp3 in M:\MUSIC\fun\Leonard Richardson
but not Kleptomania.mpeg in D:\OUT\
(as that would be parents:2)
parents:4 klep
finds 15-Kleptomania.mp3 in M:\MUSIC\fun\Leonard Richardson
but not Kleptomania.mpeg in D:\OUT\
(as that would be parents:2)
Re: How to search only 1 subdir deep?
thank you for the reply, but I wasnt able to get this right either. Could be my own inexperience - or could be a misunderstanding in what im after. Let me give you some more exact path's.
Here is my directory im trying to search
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs
within it are numerous folders such as
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\Hitman HD Trilogy (USA)
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\Iron Man (USA)
etc...
all of those folders contain numerous files and subfolders.
one file exists in the root of every one of those folders called default.xex
I need to grab all of them, the problem is, when i search I end up with more of them than their are folders due to the fact that some have multiple default.xex nested in subfolders for example....
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\Hitman HD Trilogy (USA, Europe) contains
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\Hitman HD Trilogy (USA, Europe)\HMC\default.xex as well as
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\Hitman HD Trilogy (USA, Europe)\HMSA\default.xex
i hope this makes more sense. If you understood me the first time, then its just me being slow
edit: still mucking with this. Based on your example i tried.
parents: 2 "G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" default.xex
hoping to find
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\007 Legends (USA)\default.xex
G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\2010 FIFA World Cup South Africa (USA)\default.xex
etc.
Re: How to search only 1 subdir deep?
the parents: function is also known as depth:
(see the Serach Help page for that and (much) more
Maybe that makes it a bit easier to understand?
Depth is counted from the root, in your case G:
So for G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\007 Legends (USA)\default.xex, that means default.xex has depth:6 (if I counted correctly)
With that, you can search for:
(replace depth:6 with parents:6 if you like that one better)
(don't forget the "" around the folder as it contains spaces)
(see the Serach Help page for that and (much) more
Maybe that makes it a bit easier to understand?
Depth is counted from the root, in your case G:
So for G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\007 Legends (USA)\default.xex, that means default.xex has depth:6 (if I counted correctly)
With that, you can search for:
Code: Select all
"G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" default.xex depth:6
(don't forget the "" around the folder as it contains spaces)
Re: How to search only 1 subdir deep?
nooooow i get it thank you very much for your time!NotNull wrote: ↑Mon Dec 02, 2019 8:36 pm the parents: function is also known as depth:
(see the Serach Help page for that and (much) more
Maybe that makes it a bit easier to understand?
Depth is counted from the root, in your case G:
So for G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\007 Legends (USA)\default.xex, that means default.xex has depth:6 (if I counted correctly)
With that, you can search for:(replace depth:6 with parents:6 if you like that one better)Code: Select all
"G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" default.xex depth:6
(don't forget the "" around the folder as it contains spaces)
depth does make it easier to conceptualize, but either way - i was placing the function everywhere but where it should be basically
before the directory, after it but before the file to be searched, inside the quotations etc lol.
very helpful to get me rolling. even outside of this specific search and function.
Re: How to search only 1 subdir deep?
Oooh, I have 1 more question. just for future reference.
does a means exist to search multiple subdirectories?
Say I wanted to get a file(s) from depth:6 and depth:7 in the same search? or depth:6 and depth:8
is this possible?
does a means exist to search multiple subdirectories?
Say I wanted to get a file(s) from depth:6 and depth:7 in the same search? or depth:6 and depth:8
is this possible?
Re: How to search only 1 subdir deep?
Everything has an OR function (searchA|aearchB) to combine multiple searches
Any space that is not within "" is seen as an AND function
Translated:
Show all files and folders in "G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" AND limit that to the ones that have default.xex in their names AND limit that even further by showing only the ones that are 6 OR 8 levels deep.
AND is "stronger" than OR
(see also the Help page I linked before).
Any space that is not within "" is seen as an AND function
Code: Select all
"G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" default.xex depth:6|depth:8
Show all files and folders in "G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" AND limit that to the ones that have default.xex in their names AND limit that even further by showing only the ones that are 6 OR 8 levels deep.
AND is "stronger" than OR
(see also the Help page I linked before).
Re: How to search only 1 subdir deep?
excellent information. Ill try and reference the help page going forward. Now that i understand the fundamentals much better (at least relative to how i see myself using it).NotNull wrote: ↑Tue Dec 03, 2019 5:20 pm Everything has an OR function (searchA|aearchB) to combine multiple searches
Any space that is not within "" is seen as an AND functionTranslated:Code: Select all
"G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" default.xex depth:6|depth:8
Show all files and folders in "G:\Games\Consoles\Microsoft - Xbox 360\Game Discs\" AND limit that to the ones that have default.xex in their names AND limit that even further by showing only the ones that are 6 OR 8 levels deep.
AND is "stronger" than OR OR is "stronger" than AND
(see also the Help page I linked before).
Once again, sincere thank you for your time and help!
Re: How to search only 1 subdir deep?
You're welcome!
Don't hesitate to ask your questions here on the forum if the help pages are not enough ..
Don't hesitate to ask your questions here on the forum if the help pages are not enough ..