How to implemant and use in a fetch transient properties

Hi every one,


Let's say I need to filter or sort data by a computed property thru a fetch request or a fetchedresultscontroller.


For instance entity has a attribute "name" ("The doomed cat" or "the ladd") and I want to retrieve only those with a "e" in their names but not in the articles of their names (ie I want the fetch to give me back "The doomed cat" because there's a "e" in "doomed" but not "the ladd").

So I add a computed property "noArticleName" where articles are removed and I'd like the fetch to be executed on that property ...


But when it comes to CoreData ..... If I declare that "noArticleName" attribute as a transient property in my model, when NSManagedObject subclasses are created xCode doesn't allow me to put a setter & a getter for that property as "NSManaged not allowed on computed properties" ... Ok .... So I remove "NSManaged" before this property so I can compute it but not in the extension part of the class anymore ....

No errors at build but it deeply suc... at run ("NSValidationErrorKey")!!!!

The only way to save w/o errors is to put it optional but then no way to put a fetch on it .... "unimplemented SQL generation for predicate : (noArticleName CONTAINS "e")"


Do I have to store this property as a non-transient, increasing the size of the database ?



Thanks for your help

How to implemant and use in a fetch transient properties
 
 
Q