Hi Ted, Can you define "whole bunch" are we talking thousands, millions? I follow the mantra of "First make it work, then worry about optimizing it if it is to slow."
If you are updating the same attribute on all the objects, you can simply use key-value coding. myArray.takeValueForKey(newValue, Entity.ATTRIBUTE_KEY); Also, how are you saving? Are you saving each object, or saving the EditingContext? Dave On Sep 18, 2010, at 11:38 PM, Theodore Petrosky wrote: > I have to update a whole bunch of objects. Method 1 says make a list of the > objects, make the changes and saveChanges(). Seems really inefficient. If > there were only 50 objects I would probably do that. So I created a procedure > on backend. Basically, an update of all records that match a job number. > > Of course this is making a change behind the back of my WO App. and someone > may be looking at this data. > > So what are my choices? go back to method 1. Looping through 500 records, > then saving changes? Or is there a way to selectively invalidate these > objects to force any other users to get fresh data? > > Ted > > > > _______________________________________________ > Do not post admin requests to the list. They will be ignored. > Webobjects-dev mailing list ([email protected]) > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/webobjects-dev/webobjects%40avendasora.com > > This email sent to [email protected] > > _______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [email protected]
