Searching for Extensionless Files in Windows 7

10

3

I cannot for the life of me figure out a way to have Windows 7 Explorer search for files with no extension. In XP it was nice and simple: just search for files named *. but in 7, that does not work and returns all files, as does ext:..

Searching has become extremely burdensome in Windows 7. Does anyone know how to perform this previously simple task?

Synetech

Posted 2012-01-15T02:25:47.003

Reputation: 63 242

@Synetech - Check out the answer I posted. I think it should help you filter out the files vs folders etc. and no extension and multi dot files. – Alex S – 2015-08-13T14:06:30.327

1

I'd like to see a solution with out having to resort to 3rd party apps, but this should do what you need. http://mythicsoft.com/agentransack

– skub – 2012-01-15T02:35:24.570

1

Might be a fix for Windows search here...http://www.davidlenihan.com/2009/06/teaching_windows_about_files_w.html

– Moab – 2012-01-15T02:40:49.933

Windows Search isn't the most intuitive syntax. I'm curious about the history and development of Windows Search and where did it start. – surfasb – 2012-01-15T05:25:12.210

Re: Moab's link - > Files that don't have an extension (like "makefile") do not work well in Windows. Not true; XP had no problems with extensionless files, or even nameless files (eg `.htaccess'). Sure, Explorer was a bit tricky and the command-line was easier to use for these, but there were never any problems with the search function. – Synetech – 2012-01-15T06:50:11.763

> Windows Search isn't the most intuitive syntax. I'm curious about the history and development of Windows Search and where did it start. Probably a (messy) mix between wildcards, regex, competing with Google, and excessive drug-use. I wouldn’t be so mad if it were only Windows Search that were the problem, but in Win7, even the regular search function in Explorer is broken because they decided to replace Explorer’s search function with the broken Windows Search. :roll: I don’t know what’s worse; the ineffective/difficult new syntax, or that it always takes 100% CPU to do anything/nothing. – Synetech – 2012-01-15T06:52:59.937

I'd disagree with the 100% CPU time comment. It would be painful if it didn't try to use all available CPU time. If I wanted a complete list to, say pipe into a command, then this is the wrong interface. BTW, you can still use the command line, ie dir c:\*. /s will return all files without an extension. It doesn't help with your files that end with a period, since they just cause mad problems in general. – surfasb – 2012-01-15T09:10:14.450

@surfasb, the problem is that Explorer’s search function in XP could do more without using much CPU; in 7, it always uses 100% to do the same thing, and often even nothing at all (eg simply scrolling the list or even just displaying it). And the command-line is not the same thing. You cannot perform commands on filenames; the list in Explorer lets you do things like open, delete, rename etc. much easier. My point is that the search function in 7 is horrible when compared to that of XP. Even just getting a complete list of all files is more work in 7: filename "" in XP, "*" in 7. – Synetech – 2012-01-15T17:11:48.507

@Synetechinc.: You can't select and right click files to rename?? That definitely isn't default behavior either. – surfasb – 2012-01-16T00:15:13.760

@surfasb, right-click files in the command-line? Of course not, there are no file objects in the command-line, just text. – Synetech – 2012-01-16T01:58:58.190

Ahh, you meant perform commands on filenames. Actually, dir also adds the path for you, so you just prepend it. – surfasb – 2012-01-16T02:03:44.830

Answers

13

According to MSDN, the nothing character is []. So press F3 and enter ext:[].

surfasb

Posted 2012-01-15T02:25:47.003

Reputation: 21 453

That kind of, almost works. It returns file that indeed have no extension, but it also returns some files that are labeled as having no extension even though they contain one or more periods, as well as all folders, even ones that contain periods. Hmm, it looks like Windows 7 cannot even tell the type of files and/or correctly parse filenames/extension. (I like Win7 less and less every day.) – Synetech – 2012-01-15T07:01:02.027

1Strange, files with multiple periods by definition have an extension and those files don't show up on my system. Folders have extensions also, so that isn't just for files. If you want just files you should add a filter:NOT kind:folder since it implicitly searches all object types, not just files. I can't help you with the Win 7 like/dislike. – surfasb – 2012-01-15T09:04:38.657

3

As @surfasb points out the [] can be used to represent 'nothing', and you can use it with the ext: filter.

You can then use that in combination with the type: filter and tell it to NOT show file folders:

ext:[] type:NOT"file folder"

Ƭᴇcʜιᴇ007

Posted 2012-01-15T02:25:47.003

Reputation: 103 763

1

I was facing this issue today on Windows 8 and have noticed it on previously on Windows 7 as well. I finally found a way to do this right and I hope this answer helps the original posters and others who come here via google searches.

Typically for normal as well as advanced power searches I used Nirsoft SearchMyFiles and stopped using Windows Search.

enter image description here

But, for some reason I was having trouble getting it to find files without any extensions. I figured the same bug was there in this app as well.

But, I was wrong and apparently Nir Softer has redesigned his wild card & regular expression engine from scratch; as per this little gem I found posted on the page in "Versions History" section:

  • Version 2.40:
    • SearchMyFiles now uses an internal wildcard parser instead of basing the search result on the wildcard parser of Windows. This change solves an annoying bug caused by Windows wildcard parser: In previous versions, SearchMyFiles sometimes returned incorrect results, because Windows also matches the wildcard with the short filename (8.3 DOS format).
    • Notice: The new wildcard parser may cause some compatibility issues, for example: When you scanned using . wildcard with Windows parser, it returned all files, including files without extension. With the new SearchMyFiles wildcard parser, . returns only files with extension. In order to return all files, you should use * instead of .
    • When loading old config files, SearchMyFiles automatically converts all . wildcards to *
    • The new wildcard parser has some advantages, for example: if you search for ..., you'll get all files with 3 dot characters or more. With Windows wildcard parser in previous versions, you simply got the list of all files.
    • You can now exclude files by using wildcards list. You have to select this option from the combo-box, because the default option is to exclude files by extension.
    • You can now specify environment strings in the 'Base Folders' and 'Excluded Folders' fields (For example: %AppData% )

So to find files without extensions don't use these:

*.* or *.

Just use a simple:

* 

For example :

Files Wildcard: *
Subfolders Wildcard: *

Note: Please don't go by the wild cards shown in the 'old' screenshot posted above.

Alex S

Posted 2012-01-15T02:25:47.003

Reputation: 811