Search by kMDItemKind produces incorrect results
| Originator: | pierre.bernard | ||
| Number: | rdar://19511082 | Date Originated: | |
| Status: | Open | Resolved: | |
| Product: | OS X SDK | Product Version: | 10.10 |
| Classification: | Reproducible: |
Summary: Searches for files where kMDItemKind is different from a specified value produce incorrect results. Steps to Reproduce: On an English language system, the following queries should not produce any results: mdfind "(kMDItemKind == 'Property List'c) && (kMDItemKind != 'Property List'c)" mdfind "(kMDItemKind == 'Property List'c) && (! (kMDItemKind == 'Property List'c))" mdfind -onlyin . "(kMDItemKind == 'Portable Document Format (PDF)'c) && ( ! ((kMDItemKind == 'Portable Document Format (PDF)'c) ))" Expected Results: Searching for files where kMDItemKind both is equal to and different from a same value should not produce results. Actual Results: The queries produce results. They however behave as if the second clause was omitted: ~ (pierre)> mdfind "(kMDItemKind == 'Property List'c) && (kMDItemKind != 'Property List'c)" | wc -l 28382 ~ (pierre)> mdfind "(kMDItemKind == 'Property List'c) && (! (kMDItemKind == 'Property List'c))" | wc -l 28382 ~ (pierre)> mdfind "(kMDItemKind == 'Property List'c)" | wc -l 28382
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!