• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Core Data, sorting on dependent values
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Core Data, sorting on dependent values


  • Subject: Core Data, sorting on dependent values
  • From: MickaĆ«l Remars <email@hidden>
  • Date: Thu, 26 Jul 2007 12:41:32 +0200

Hello,

I face an issue with Core Data and sorting.

Model side, I have a 'Person' entity. 'Person' has 'firstName' and 'lastName' attributes coded within Core Data model. Then, I have a *derived value* 'fullName'.
Interface side, I have an NSArrayController based on 'Person' entity. I also have an NSTableView which one column is bind to derived value 'fullName'.


Now what I want to achieve is to sort table view by column 'fullName' *before* displaying the table. In other words, I don't want the end- user to sort manually, at least on application startup. So, when I *programatically* apply a sort descriptor based on 'fullName' key, Core Data complains that 'fullName' is not part of entity model. (I agree off course agree with that).

Does it mean that it is not possible to sort on a derived value when using Core Data ?
If so, how can I implement that kind of sorting ?



Thank in advance _______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Core Data, sorting on dependent values
      • From: Dave Fernandes <email@hidden>
  • Prev by Date: Re: Enabling menu items?
  • Next by Date: Re: Enabling menu items?
  • Previous by thread: floating point NSBitmapImageRep
  • Next by thread: Re: Core Data, sorting on dependent values
  • Index(es):
    • Date
    • Thread