Transient sectionNameKeyPath & NSSortDescriptor NSFetchedResultsController Transient sectionNameKeyPath & NSSortDescriptor NSFetchedResultsController xcode xcode

Transient sectionNameKeyPath & NSSortDescriptor NSFetchedResultsController


The simplest solution is to add a persistent 'section' attribute (or convert your existing transient attribute). Make it a set of sortable values (which you display at runtime using the names you want). Whenever you update any record, recompute and store the section attribute as well.

I realize this sounds like you're storing redundant information but besides making your logic simpler, it will also be indexable which will speed access.