Please tell me what I'm doing wrong.
I want to find duplicate .png files in subdirectories below 'L:\Pictures\'
So I'm using the Selection Assistant: 'Select by text pattern' where column name = path.
I've set the regexpression = ^L:\\Pictures\\.*\\*.png$
eg. this file should match - 'L:\Pictures\abc\def\ghi\jkl.png' but it doesn't.
The expression works in this online tester: https://regex101.com/r/fW4aL8/1
but it doesn't in Duplicate Finder. Any help would be appreciated. Thanks.
Please help: Regular expressions
Re: Please help: Regular expressions
Can't answer on the regex end, but why are you even needing regex in this case?
Why not set the Location: to L:\Pictures & the Filter: to *.png ?
Why not set the Location: to L:\Pictures & the Filter: to *.png ?
Re: Please help: Regular expressions
Bump... Can someone please confirm that regular expressions work and tell me what I'm doing wrong?
Re:
Re:
The location is set to multiple paths and I don't want to have to throw away the time it required to do that search and take more time doing multiple sub-searches. Seems to me that RegEx would take the minimum time to filter already performed searches without having to search again.Can't answer on the regex end, but why are you even needing regex in this case?
Why not set the Location: to L:\Pictures & the Filter: to *.png ?
- DigitalVolcano
- Site Admin
- Posts: 1864
- Joined: Thu Jun 09, 2011 10:04 am
Re: Please help: Regular expressions
^L:\\Pictures\\.*\\*.png$
This won't work as the filename (*.png) part is in a different column - it will only match on the selected column (path) unfortunately.
The best way to do this with the current version is-
Selection Assistant ->Work only on currently selected rows = checkmarked
Sort by folder name and select (highlight row) all folders below L:\Pictures
Selected Assistant->Select by text pattern, column='File name' pattern = .png (non-regex) or png$ (regex)
This won't work as the filename (*.png) part is in a different column - it will only match on the selected column (path) unfortunately.
The best way to do this with the current version is-
Selection Assistant ->Work only on currently selected rows = checkmarked
Sort by folder name and select (highlight row) all folders below L:\Pictures
Selected Assistant->Select by text pattern, column='File name' pattern = .png (non-regex) or png$ (regex)
Re: Please help: Regular expressions
Question: Why does the tool allow sorting by columns, all except by "File Type"? To me, this seems like a bug.^L:\\Pictures\\.*\\*.png$
This won't work as the filename (*.png) part is in a different column - it will only match on the selected column (path) unfortunately.
It would also be nice to first sort by file type and then by path, or the opposite.
Additionally, shouldn't the selection assistant -> select by text pattern -> column name = file name, accept wild cards? Why can't I search for *.png (or *.p*) given that the extension is part of the file name?
Thank you.
- DigitalVolcano
- Site Admin
- Posts: 1864
- Joined: Thu Jun 09, 2011 10:04 am
Re: Please help: Regular expressions
If you want a wild card you'll need to use a regex.
e.g.
Alternately you can right-click on the file type you require and select Mark->All files of this type.
e.g.
Code: Select all
\.png$