On Wed, May 20, 2009 at 8:25 AM, Aurélien Hugelé <hugele.aurel...@objective-decision.com> wrote: > There clearly is a difference since fetching is *much* slower that > objectWithID: then testing using try/catch is the object is a fault or not.
Read the -[NSManagedObjectContext obtainPermanentIDsForObjects:error:] docs carefully: "This method results in a transaction with the underlying store which changes the file’s modification date." Think about that for a second. You're essentially saving the store to disk for each time you call -obtainPermanentIDsForObjects:error: (it's not really a "save" in the Core Data sense, but it is writing the store out to disk every time). Either batch all your requests up in one call to -obtainPermanentIdsForObjects:error:, or don't call it. --Kyle Sluder _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com