• 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: Partially saving the object graph. How? (Jean Pierre Malrieu)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Partially saving the object graph. How? (Jean Pierre Malrieu)


  • Subject: Re: Partially saving the object graph. How? (Jean Pierre Malrieu)
  • From: Jean Pierre Malrieu <email@hidden>
  • Date: Mon, 19 Mar 2007 20:34:36 +0100


Le 19 mars 07 à 18:25, Chuck Hill a écrit :

Hi Jean,


On Mar 19, 2007, at 10:13 AM, Jean Pierre Malrieu wrote:

It depends on what you are doing with entity B.

If you are not modifying any B objects, then you don't need to do
anything because only updated/inserted/deleted objects in the editing
context will get committed to the database.

I am modifying them. I am inserting them, then modifying them. Most of the time, they are saved along with instances of entity A. But in one app of mine, they must not be saved.

Then delete them. If you delete an inserted object, it will not be saved.

Not possible. I need them after saving...



If you are modifying A and B objects, then you can't just commit A
changes because both A and B objects must be part of the same editing
context. If this is what you need to do, then i think you might to
reconsider your model.

Rethinking the emodel is not an option here, I am affraid.

You are going to have to re-think something!


Basically, what gets committed is determined by the editing context you
call saveChanges() on. This is what determines the DB transaction.

Sure. I was wondering if the best strategy would be to override saveObject() in a subclass of EOEditingContext in order to skip entity B's inserts an updates.
Would that entail violating EOF commandments?

Here is what I would do. Go outside. Find a large road. Wait for a bus or large truck. Lie down in front of it. You will find this is quicker and less painful. :-)

Not being very tall, and lying parallel to the road, I was hoping EOF bus would drive over me without hurting me...


JPM


_______________________________________________ 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: Partially saving the object graph. How? (Jean Pierre Malrieu)
      • From: Chuck Hill <email@hidden>
References: 
 >Re: Partially saving the object graph. How? (Jean Pierre Malrieu) (From: Jean Pierre Malrieu <email@hidden>)
 >Re: Partially saving the object graph. How? (Jean Pierre Malrieu) (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: Custom Component Problems
  • Next by Date: Re: Partially saving the object graph. How?
  • Previous by thread: Re: Partially saving the object graph. How? (Jean Pierre Malrieu)
  • Next by thread: Re: Partially saving the object graph. How? (Jean Pierre Malrieu)
  • Index(es):
    • Date
    • Thread