Keypath not found in entity

后端 未结 2 1569
后悔当初
后悔当初 2020-12-16 16:06

I want to show a formatted date in the section header of a table view..

I used the following code.but its throwing an exception *** Terminating app due to unca

相关标签:
2条回答
  • 2020-12-16 16:43

    The title of your question indicates that "dateSectionIdentifier" is a transient property.

    You cannot use a transient property in a sort descriptor (or in a predicate) of a Core Data fetch request if SQLite is used as store type. That is a documented restriction, only persistent properties can be used.

    See Persistent Store Types and Behaviors in the "Core Data Programming Guide" for more information.

    0 讨论(0)
  • 2020-12-16 16:51

    I think you would have added "dateSectionIdentifier" in the subclass, but not updated in the .xcdatamodelId file. Cross check to see whether you have added "dateSectionIdentifier" in .xcdatamodelId file or not.

    0 讨论(0)
提交回复
热议问题