Am 17.05.2006 13:16 Uhr schrieb "David Avendasora" unter
<[EMAIL PROTECTED]>:

Thanks David!

I removed one flattened relationship that was a relict of a join in many to
many, which i afterwards changed to a real entity where i allocate rows
programmatically.
Solved!

Wolfram

> I have been getting this using flattened many-to-many relationships
> where my join-table has its own primary key (not compound of the two
> foreign keys). As soon as I quit using a flattened relationship, I
> quit getting the error.
> 
> I don't know if the independent primary key was actually causing the
> problem or not.
> 
> Dave
> 
> 
> On May 17, 2006, at 12:09 PM, Wolfram Stebel wrote:
> 
>> Hi List,
>> 
>> i have a problem to analyse the following error:
>> 
>> java.lang.IllegalStateException: A valid global ID could not be
>> obtained for
>> entity named Class_Hour, relationship named location_Rooms, primary
>> key
>> dictionary {fk_location_room = 5; fk_class = 26; }
>> 
>> Stack:
>> 
>> EODatabaseContext.java    5062
>> databaseOperationForIntermediateRowFromSourceObject
>> com.webobjects.eoaccess
>> EODatabaseContext.java    5086
>> recordDeleteForIntermediateRowFromSourceObjectRelationshipDestinationO
>> bject
>> com.webobjects.eoaccess
>> EODatabaseContext.java    5139
>> nullifyAttributesInRelationshipSourceObjectDestinationObject
>> com.webobjects.eoaccess
>> EODatabaseContext.java    5166
>> nullifyAttributesInRelationshipSourceObjectDestinationObjects
>> com.webobjects.eoaccess
>> EODatabaseContext.java    6056    recordChangesInEditingContext
>> com.webobjects.eoaccess
>> EOObjectStoreCoordinator.java    412    saveChangesInEditingContext
>> com.webobjects.eocontrol
>> EOEditingContext.java    3187    saveChanges
>> com.webobjects.eocontrol
>> OneClassPage.java    166    deleteClass
>> ....
>> 
>> 
>> Code in deleteClass:
>> 
>> theClass.validateForDelete ();          // does not raise!
>> ec.deleteObject ( theClass );
>> ec.saveChanges ();
>> 
>> 
>> The entities are:
>> 
>> Relations:    Class<-->>ClassHour<<-->location_Room<<-->Location
>>                                  <<-------------------->
>> 
>> Optional:           opt            opt              opt
>>                                             opt
>> 
>> Delete Rule:       casc->          null           <-casc
>>                                             null
>> 
>> "fk_location_room" and "fk_class" from the error primary key
>> dictionary are
>> both in "ClassHour".
>> The relation "location_Rooms" from the error message is from
>> "Class" to
>> "Class_Hours.location_Room", "Class_Hours" is from "Class" to
>> "ClassHours"
>> 
>> When i delete a "Class" with a "ClassHour" assigned, that points to a
>> "Location" and a "location_Room" i get the above mentioned error. (A
>> "location_Room" can only be assigned when a "Location" is assigned
>> before.)
>> 
>> Any ideas for a solution?
>> 
>> Wolfram


 _______________________________________________
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]

Reply via email to