I have the following Aurelius design(using FireDac):
Master
->DetailDoc
->DetailItem
-->DetailItemDoc
I have defined a ManyValuedAssociation(CascadeTypeAllRemoveOrphan) for every Detail entity.
I can add and remove ok for DetailDoc and DetailItem for Master.
I can add ok a DetailItemDoc to DetailItem, but when I try to remove a DetailItemDoc from DetailItem I get the following exception:
"Class TFDDatSTable is not a valid Entity. [Entity] attribute missing or entity does not belong to model."
at Manager.Flush;
Other than this, such message might be caused because you the entity is in the list but is destroyed. If you somehow destroy an item, calling Free or Manager.Remove, also make sure you remove them from the lists they belong.
Third, make sure your lists are TList, not TObjectList, or at least, if they are TObjectLlist, make sure they don't destroy the objects they contain when they are removed.
If nothing above helps, please send a minimum compilable project reproducing the issue.