Strange problem: object with globalID not found in database
Strange problem: object with globalID not found in database
- Subject: Strange problem: object with globalID not found in database
- From: Timo Höpfner <email@hidden>
- Date: Thu, 11 Mar 2004 16:00:01 +0100
Hi,
I have a strange problem for which I cannot find a solution for. I'm
quite new to WebObjects so please forgive me it there is an obvious
solution...
I have two entities in different Models. The Entity in the first model
represents a shopping cart with ordered files, which optionally holds a
reference of an archive (zip) of these files. The archive is
represented by another entity in another model.
When the reference to the archive is set, I get the following error
upon loading the shopping cart entity:
java.lang.IllegalStateException: The object with globalID
_EOIntegralKeyGlobalID[PhysicalFile (java.lang.Integer)18] could not be
found in the database. This could be result of a referential integrity
problem with the database. An empty fault could not be created because
the object's class could not be determined (e.g. the GID is temporary
or it is for an abstract entity).
The data is definitely in the database, and the problem vanishes, if I
do an unqualified fetch on the entity representing the Archive before
accessing the shopping cart entity.
(EOUtilities.objectsForEntityNamed(session().defaultEditingContext(),
"PhysicalFile")). But this is no real workaround, as the concerned
tables can become quite large and the unqualified fetch would be a
performance bottleneck...
I'm using single-table inheritance to distinguish between file system
roots (parent allowed to be null) and ordinary files (parent must be
set).
What can I do? This is a real show-stopper for me...
Timo
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.