solved: prepareForSaveWithCoordinator: Cannot save the object with globalID / row does exist
solved: prepareForSaveWithCoordinator: Cannot save the object with globalID / row does exist
- Subject: solved: prepareForSaveWithCoordinator: Cannot save the object with globalID / row does exist
- From: OC <email@hidden>
- Date: Sat, 07 Feb 2015 03:17:03 +0100
Dave, Chuck, and others,
well, if the error in code is hard to find, it sometimes might mean it's not there.
I think I did write the problems happen on a server to which I had no access; just I was getting logs and other things I asked the admin for.
Now I have obtained the access to the server, for “being able to catch the bugs” POV prevailed over too-tight security.
You can guess exactly once.
To cut long story short, for diverse testing, a couple of versions of the app with different settings and over different databases runs on the server, and they kept feeding me DB and sometimes even archived application logs from _another_ version than the one which triggered the problem! Oh, sigh. Well my fault too -- I should have checked e.g., the properties logged out launch-time :/
So the framework was completely right, they simply did delete the object in the clone which reported the error, without deleting objects which kept reference to it.
(Incidentally, _after_ I have found it in -- this time the right -- log, one of testers miracuously did recall he actually deleted something over an alert “Make sure this is not used anywhere before deletion, otherwise you might cause inconsistencies in the DB”. He said “well it was an old thing, not needed anymore, so what?” Great.)
Just for completeness' sake...
On 6. 2. 2015, at 17:58, David Avendasora <email@hidden> wrote:
> How about EOF doing things out-of-(expected)-order?
>
> ec.saveChanges() creates 1 transaction.
>
> Let’s say you’ve made a bunch of changes, one of which results in an EO being deleted (cascade-delete, owned objects, etc),
Which “etc” can happen here? I still haven't found the precise culprit for
http://prod.lists.apple.com/archives/webobjects-dev/2014/Nov/msg00163.html
> but because other EOs that would have been related to it were added before it was deleted from the ec.
This time (having the right log :)) I would know -- after the problem I've added logging out all Adaptor Operations in my databaseContextWillPerformAdaptorOperations delegate method (actually that was where I've found the object really has been deleted as soon as I've found the trick with wrong logs).
Thanks and all the best,
OC
_______________________________________________
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