database save problem
CapableObjects Forums
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        



database save problem Expand / Collapse
Author
Message
Posted 2008-12-20 01:22:43
Forum Member

Forum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum Member

Group: Forum Members
Last Login: 2012-01-13 15:57:45
Posts: 48, Visits: 1 645
Hello!

When saving to a database, I got this error message:
"When storing link ObjectComposition.CoReDetailObject, the link reffered to an internal object id. The object at the other end must be stored first. Please mark the link as a constrained link in the OR-mapping."

Saving is done as EcoSpace.UpdateDatabase(). This is the first time when I see this message, though the database already contains a few hundred thousand objects. Any ideas?

Best regards,
Dmitry
Post #1495
Posted 2008-12-20 05:10:21
Forum Member

Forum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum Member

Group: Forum Members
Last Login: 2012-01-13 15:57:45
Posts: 48, Visits: 1 645
I found what was causing the problem: I was linking a deleted object. Strange enough, in most cases it would allow to save, but a database would then contain phantom records in association tables, which in turn would cause ObjectNullReference exception on trying to read objects with these phantom links.

Take care,
Dmitry
Post #1496
Posted 2008-12-20 18:55:18
Supreme Being

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being

Group: Administrators
Last Login: 2010-11-30 12:17:13
Posts: 1 230, Visits: 1 382
Could you please file a bug report on this? It should throw an exception immediately when you try to create an association to a deleted object.

/Jonas Hogstrom [CapableObjects]
Post #1497
Posted 2008-12-20 19:58:29
Forum Member

Forum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum Member

Group: Forum Members
Last Login: 2012-01-13 15:57:45
Posts: 48, Visits: 1 645
Submitted as http://magpie.no-ip.com/mantis/view.php?id=670

Best regards,
Dmitry
Post #1498
« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: HansKarlsen, Jonas Hogstrom, PeterMorris

Permissions Expand / Collapse

All times are GMT +1:00, Time now is 12:14

Powered By InstantForum.NET v4.1.4 © 2012
Execution: 0,250. 9 queries. Compression Disabled.