How do I search in a folder but not subfolders?

If you are experiencing problems with "Everything", post here for assistance.
Post Reply
ctx
Posts: 3
Joined: Tue Oct 04, 2022 8:52 am

How do I search in a folder but not subfolders?

Post by ctx »

Basically what the title says. Is it possible to search inside a folder while excluding the subfolders?
void
Developer
Posts: 16750
Joined: Fri Oct 16, 2009 11:31 pm

Re: How do I search in a folder but not subfolders?

Post by void »

Please try the parent: search function, for example:

parent:c:\windows
parent:"c:\program files"

PS. Please update your forum email address (address unknown) from your name at the top right -> User Control Panel -> Profile -> Edit account settings -> Email address
therube
Posts: 4977
Joined: Thu Sep 03, 2009 6:48 pm

Re: How do I search in a folder but not subfolders?

Post by therube »

Can this or parents: or some other way do this (no-sub-folders:) but with relative or partial paths?


Say I have two trees:

Code: Select all

C:\out\COPY\X\
X:\Z\out\COPY\X\
can I do a search of
/out/COPY/X/

but not subfolders ?


I could use parents:, but in this case they're at different directory levels.
So parents:3 would work for one, & parents:4 would work for the other, but not both.
(And a parents:3-4 would also not work, because then any potential unwanted subdirectory could be picked up.)

And I could use parent:, but then I need full paths to each, & an or:
parent:C:\out\COPY\X\ | X:\Z\out\COPY\X\

(all of which isn't particularly convenient to enter).
NotNull
Posts: 5461
Joined: Wed May 24, 2017 9:22 pm

Re: How do I search in a folder but not subfolders?

Post by NotNull »

therube wrote: Thu Mar 23, 2023 4:56 pm And I could use parent:, but then I need full paths to each, & an or:

Code: Select all

parent:C:\out\COPY\X\ | X:\Z\out\COPY\X\
That will not work. One of the following will:
parent:C:\out\COPY\X | parent:X:\Z\out\COPY\X
parent:<C:\out\COPY\X\|X:\Z\out\COPY\X\> (no spaces around |)
parent:<C:\out\COPY\X|X:\Z\out\COPY\X> (no spaces around |)
parent:C:\out\COPY\X\;X:\Z\out\COPY\X (requires Everything 1.5)

And with Match whole filename when using wildcards enabled (Options => Search) this will do:

Code: Select all

\out\COPY\X\*
(requires Everything 1.5)
therube
Posts: 4977
Joined: Thu Sep 03, 2009 6:48 pm

Re: How do I search in a folder but not subfolders?

Post by therube »

And with Match whole filename when using wildcards enabled (Options => Search) this will do:
I think I might like that.
I'll have to see how it goes...
Post Reply