Posey's Tips & Tricks

How To Narrow Down Windows Search

Filter your search queries to locate what you're looking for.

The Windows Search feature is one of those things that I find myself using constantly. Even though I keep all of my data well organized, I find myself using the search filter on a daily basis. For instance, if I am thinking about writing a blog post, I will often do a search to figure out if I have ever written about the topic before. Herein lies the problem. Even though the Windows Search feature is really powerful, the Search interface leaves a lot to be desired.

One of the really handy things that you can do using the Search tool is to index network locations so that you can search for data that resides outside of the Windows libraries. When you enable indexing, Windows actually parses your documents so that you can search documents based on their contents, not just based on the document title. Sometimes though, you might only want to see search results that are based on a document's filename (as opposed to the document's contents) and Windows doesn't give you an obvious way of performing such a search.

Earlier I said that I sometimes use the Windows search feature to see if I have ever written about a particular topic before. Since the blog post that you are reading right now is all about search, let's see what happens if I enter the word Search into the Windows search box.

As you can see in Figure 1, some of my search results were given because the word search appeared in the document title. In other cases, the word search appeared inside of the document body.

[Click on image for larger view.] Figure 1. Some of the documents listed among the search results include search in the filename while others do not.

 If I had ever written a blog post about Windows search in the past, the word "search" would most likely appear in the document's filename. This would be handy to be able to filter the results so that documents that simply contain the word "search" somewhere in the document body are excluded from the results. So how can you do that?

Even though the search interface provides very few options for filtering your search results, there are a number of text-based filters that you can use. To show you how this works, let's go back to my previous example of only wanting to find documents that use the word "search" in the filename. To do so, I could enter Name:Search within the search bar. As you can see in Figure 2, my results have now been filtered to omit any document in which the word "search" only appears in the body, but not the filename.

[Click on image for larger view.] Figure 2. The results have been filtered so that documents are only listed if the word search appears in the filename.

Name isn't the only filter that you can use in the Windows search box. There is also a Tag filter. If you routinely apply tags to your documents then you can use the Tag filter to search based on those tags. If, for example, I wanted to look for documents that include a Windows11 tag then I would type Tag:Windows11.

Another super useful filter is the Modified filter. To see why this filter is so beneficial, take a look at Figure 3. As you can see in the figure, this particular document was created on Nov. 28, 2015. The problem is that this document wasn't created in 2015 -- it was created in 2001. The reason why the document's created date is set to 2015 was because that was the year when I purchased a new storage array. You can see when the document was actually created (or to be more precise, when it was last modified) by looking at the Modified date.

[Click on image for larger view.] Figure 3. A file's creation date is often wrong.

The Modified filter lets you search for files based on the date when they were modified. You can search based on a specific date (Modified:12/03/2001) or you can search based on the year when the document was modified (Modified:2001). As you can see in Figure 4, I wrote a lot of content on December 3, 2001.

[Click on image for larger view.] Figure 4. You can search for a file based on when it was modified.

Hopefully you are beginning to see just how useful search filters can be. It's worth noting that you aren't limited to using one filter at a time. You can combine the filters that I have shown you by using Boolean expressions such as AND, OR, or NOT.

About the Author

Brien Posey is a 22-time Microsoft MVP with decades of IT experience. As a freelance writer, Posey has written thousands of articles and contributed to several dozen books on a wide variety of IT topics. Prior to going freelance, Posey was a CIO for a national chain of hospitals and health care facilities. He has also served as a network administrator for some of the country's largest insurance companies and for the Department of Defense at Fort Knox. In addition to his continued work in IT, Posey has spent the last several years actively training as a commercial scientist-astronaut candidate in preparation to fly on a mission to study polar mesospheric clouds from space. You can follow his spaceflight training on his Web site.

Featured

comments powered by Disqus

Subscribe on YouTube