How to search/filter with double-quoted strings?

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
Jerry
Posts: 805
Joined: 05 May 2010 15:48
Location: The UnUnited States of America

How to search/filter with double-quoted strings?

Post by Jerry »

Either we have a bug here (17.60.0006), or I'm getting tripped up again on really basic search/filter syntax. I'm trying to do a quick search or filter with a quoted string, "Act I " to pluck out just the Act I files in the following list of files below, but I keep getting empty results. What's wrong?
  • Code: Select all

    02 - Romeo and Juliet - Act I - No 2 - Romeo.flac
    02 - Romeo and Juliet - Act II - No 26 - The Nurse.flac
    03 - Romeo and Juliet - Act I - No 3 - The street awakens.flac
    03 - Romeo and Juliet - Act II - No 27 - The Nurse delivers Juliet's letter to Romeo.flac
    04 - Romeo and Juliet - Act I - No 4 - Morning dance.flac
    
Last edited by Jerry on 26 Feb 2017 18:22, edited 1 time in total.
Running on Windows 10 Pro 64-bit quad-core ASUS G752-VY notebook with 64 GB RAM, over 26 external USB3 drives attached via multiple powered hubs with letters and mount points, totaling 120+ TB.

admin
Site Admin
Posts: 60595
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: How to search/filter with quoted strings?

Post by admin »

Air code but I'd try this:

Code: Select all

*Act I *

Jerry
Posts: 805
Joined: 05 May 2010 15:48
Location: The UnUnited States of America

Re: How to search/filter with quoted strings?

Post by Jerry »

admin wrote:Air code but I'd try this:

Code: Select all

*Act I *
Ok, that works. But honestly, why shouldn't quoted strings work as they do in just about every other application one uses? I could easily see new users getting pretty confounded by this. I'm not provoking anything here, this was a genuine, non-intuitive confusion for me, after years of using XY.
Running on Windows 10 Pro 64-bit quad-core ASUS G752-VY notebook with 64 GB RAM, over 26 external USB3 drives attached via multiple powered hubs with letters and mount points, totaling 120+ TB.

admin
Site Admin
Posts: 60595
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: How to search/filter with quoted strings?

Post by admin »

Double-quoted patterns mean "exact match" (pattern is not auto-wrapped in wildcards).

Jerry
Posts: 805
Joined: 05 May 2010 15:48
Location: The UnUnited States of America

Re: How to search/filter with double-quoted strings?

Post by Jerry »

admin wrote:Double-quoted patterns mean "exact match" (pattern is not auto-wrapped in wildcards).
The omission of implicit flanking wildcards is a non-standard restriction on the usual understanding of double-quoted string search, in my experience. File Explorer doesn't do this, for just one example, and that's the most revelant example. One common reason to resort to regular expressions is to deliberately anchor the match at the beginning or end, because the default search behavior in most applications is not to do that, double-quoted or not.

UPDATE: Actually File Explorer (Windows 10) is a bit peculiar also. I can distinguish the Act II from Act I files using my double-quoted expression, "Act I ", as expected. But if I omit the trailing space, using "Act I", then it will still only match the Act I files when I would otherwise expect it to include the Act II files as well. Also, it seems to ignore multiple spaces between the double-quotes and treats them as just one space. But nevertheless -- it is NOT requiring an exact match comprising the full length of the filename.
Running on Windows 10 Pro 64-bit quad-core ASUS G752-VY notebook with 64 GB RAM, over 26 external USB3 drives attached via multiple powered hubs with letters and mount points, totaling 120+ TB.

admin
Site Admin
Posts: 60595
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: How to search/filter with double-quoted strings?

Post by admin »

This has been a rule in XY ever since and across the app.

Tip: You can show the parsed search query of the most recent search in the current pane (it's stored for each pane separately), in a human-friendly format, using this script:

Code: Select all

text <get find_queryparsed>;
Call it right after the search to see how the search pattern has been parsed.

Post Reply