cocoa - NSDate constant for Fetch Predicate -
i'm using fetch predicate in ib filter our default result return core data , i'm looking this:
datecreated < yesterday
where "yesterday" supposed nsdate constant yesterday result return before yesterday.
this didn't work. , searching didn't turn related i'm wondering want here possible.
irrespective of core data (because has nothing core data, predicates), query (before date) normal, predicate syntax has no facilities "natural language" dates.
you pass in date object , that's that. it's create appropriate date object represent "yesterday".
to same sort of "automatic" behavior you're looking for, bind array controller's fetch predicate controller via key (kvc-compliant method) "beforeyesterdaypredicate" ... method hand dynamically-generated predicate you'd create code.
Comments
Post a Comment