When searching for versions (file_v1) the results include all files with v in their name, or extension. SUMMARY I accidentally ran BQM without changing the option to overwrite original file, so ended up with lots of _v1 files. To find these I ran search with _v as filename to match. The results included .Avi .WAV and other files that have the letter v in their name, or extension, but not the underscore. STEPS TO REPRODUCE 1. Click on Search | New Advanced Search 2. Enter _v in the filename | click on OK 3. Cherck the results OBSERVED RESULT EXPECTED RESULT SOFTWARE/OS VERSIONS Windows: macOS: (available in the Info Center app, or by running `kinfo` in a terminal window) Linux/KDE Plasma: KDE Plasma Version: KDE Frameworks Version: Qt Version: ADDITIONAL INFORMATION
OBSERVED RESULT EXPECTED RESULT SOFTWARE/OS VERSIONS Windows: 11 macOS: (available in the Info Center app, or by running `kinfo` in a terminal window) Linux/KDE Plasma: Fedora 43 KDE Plasma Version : 6.5.3 KDE Frameworks Version: 6.20.0 Qt Version: 6.10.1 ADDITIONAL INFORMATION
It's a "LIKE" database search. You need to escape such characters with a "\" at the front. So type: \_v Maik
This is the old Bug 430147 from when we added the escape function to SQLite as well. Maik
Hi Maik, Can we do the special characters escape automatically ? As i know, if we search file name with these characters must be prepared previously: - _ : \_ - % : \% - ' : '' - " : "" - ; : must be removed as it close an sql instruction. I'm right ? Gilles
There aren't many characters that need to be escaped in a LIKE SQL statement; see this MS Doc. The underscore is one of them. https://learn.microsoft.com/en-us/sql/t-sql/language-elements/like-transact-sql?view=sql-server-ver15#using-wildcard-characters-as-literals The semicolon (";") as the end character is generally unproblematic, since we already encapsulate the search strings in the SQL statement. I'll look into whether we can escape characters in SQL statements in general and whether there might be any side effects. Maik