You are not logged in.
I have 2 classes A and B which inherit from a base class C.
A has a collection of B references
B has a reference to A.
These are implemented in my PODO objects as a TCollection (using generics) of B's and as a reference to A (+ some mechanisms to manage auto-updates of the inverse relationships when needed).
When I used the ComputeSQLRecord operation, it got it completely wrong: it implemented the reference to A in B as taking all the direct attributes of A (not the inherited ones from C) and putting them directly in B. Naturally the inherited attributes from C will be different in objects A and B.
Why would it not create an object relationship? Should it be done by hand?
Best regards,
Thierry
Offline
I never used TCollection + generics with mORMot.
So perhaps there is an issue about this kind of classes.
The PODO in mORMotDDD.pas are expected to be plain aggregates, i.e. with NO direct relationship.
See http://martinfowler.com/bliki/Aggregate.html
and http://synopse.info/files/html/Synopse% … l#TITL_124
and http://synopse.info/files/html/Synopse% … ml#TITL_29
Lists are natively stored as T*ObjArray in mORMotDDD.pas.
But perhaps this is not your problem, and I've not understood your issue.
Online