> On 17 Feb 2017, at 22:35, sqwarqDev wrote:
>
> mdfind on the command line returns all the results from the /Application
> Support folder. NSMetadataQuery doesn’t return anything at all.
Search scope is set to NSMetadataQueryLocalComputerScope in case anyone was
going
> On 17 Feb 2017, at 22:25, Keary Suska wrote:
>
> The correct syntax is probably:
>
> kMDItemFSName ==[c] *%@*
>
Yeah, I’ve just been playing with that since my last post. Indeed, I discovered
that the docs claim that this should be equivalent to contains:
> On Feb 17, 2017, at 7:41 AM, sqwarqDev wrote:
>
> So eventually I discovered that this question has a history. Back in 2008
> Keary and Garriet discussed this:
>
>
So eventually I discovered that this question has a history. Back in 2008 Keary
and Garriet discussed this:
http://webcache.googleusercontent.com/search?q=cache:HXWdzJeGeDcJ:www.cocoabuilder.com/archive/cocoa/208612-nspredicate-containing-contains.html+=4=th=clnk=th=safari
Alas, none of that
Suggestions from Shane and Steve:
> Use LIKE instead of CONTAINS?
Yeah, that was my first thought. Alas, it doesn’t return the correct results.
> Try quoting the right side? "kMDItemFSName contains[cd] '%@‘"
Doesn’t return the correct results in 10.11. There aren’t any spaces in my
actual
On 17 Feb 2017, at 10:54 am, sqwarqDev wrote:
>
> Still looking for help with this, if anyone’s got any idea?
Use LIKE instead of CONTAINS?
--
Shane Stanley
,
___
Cocoa-dev mailing list
On Feb 16, 2017, at 17:54, sqwarqDev wrote:
>
> Still looking for help with this, if anyone’s got any idea?
>
>> On 15 Feb 2017, at 22:50, sqwarqDev wrote:
>>
>> Building with Xcode 7.3.1, macOS 10.11.6
>>
>> I’m using an NSPredicate with the form:
Still looking for help with this, if anyone’s got any idea?
> On 15 Feb 2017, at 22:50, sqwarqDev wrote:
>
> Building with Xcode 7.3.1, macOS 10.11.6
>
> I’m using an NSPredicate with the form:
>
> NSString *targetString = @“some string or other”;
> NSPredicate
Building with Xcode 7.3.1, macOS 10.11.6
I’m using an NSPredicate with the form:
NSString *targetString = @“some string or other”;
NSPredicate *searchPredicate = [NSPredicate predicateWithFormat:@"kMDItemFSName
contains[cd] %@“, targetString]];
When I build and run my app, this runs fine on