• 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] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Core Data] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????


  • Subject: [Core Data] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????
  • From: Aurélien Hugelé <email@hidden>
  • Date: Wed, 20 May 2009 12:03:32 +0200

Hi list !

I have a subthread that sends to my main thread some objectIDs (of objects it inserted in the same store (same PSC))
I have 2 MOCs, one per thread, sharing the same PSC (following advices from the doc...)


In the main thread, using objectWithID: repeatedly on each objectID sent by the subthread returns the object that was inserted in the background thread. This is exactly what I want.
But reading from the doc, it seems that we are encouraged to use a fetch using "self IN %@",listOfObjectIDs instead of objectWithID: since it is faster for many objects...


Unfortunately, this fetch returns 0 results (and yes this is the correct entity, store and moc...)

what does objectWithID: *exactly* do that a fetch does not ??

Thanks for your help.

Aurelien


Aurélien, Objective Decision Team




_______________________________________________

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] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????
      • From: Aurélien Hugelé <email@hidden>
    • Re: [Core Data] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????
      • From: Aurélien Hugelé <email@hidden>
  • Prev by Date: Re: Search menu item not appearing in Help menu in some locales
  • Next by Date: Re: Bindings and KVO of View objects
  • Previous by thread: Contextual Menu Plugin - not getting registered??
  • Next by thread: Re: [Core Data] Difference between objectWithID: and a fetch "self IN %@", someObjectIDs ????
  • Index(es):
    • Date
    • Thread