• 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
Re: EOEditingContext help
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EOEditingContext help


  • Subject: Re: EOEditingContext help
  • From: David Avendasora <email@hidden>
  • Date: Sun, 19 Sep 2010 07:01:02 -0400

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@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
>

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: EOEditingContext help
      • From: Theodore Petrosky <email@hidden>
References: 
 >EOEditingContext help (From: Theodore Petrosky <email@hidden>)

  • Prev by Date: Migrations and Application's finishInitialization()
  • Next by Date: Re: Migrations and Application's finishInitialization()
  • Previous by thread: EOEditingContext help
  • Next by thread: Re: EOEditingContext help
  • Index(es):
    • Date
    • Thread