9
Why does the former of following snippets work while not the latter ?
Snippet 1
NSPredicate *predicate = [NSPredicate predicateWithFormat:@"(coin_unique == %@)", [NSNumber numberWithInt:species]];
Snippet 2
// Does NOT Work
NSString *predicateText = @"coin_unique";
NSPredicate *predicate = [NSPredicate predicateWithFormat:@"(%@ == %@)", predicateText, [NSNumber numberWithInt:species]];
I have to dynamically create predicate depending upon the argument received in my method.