Hi,
When I create a new object and an underlying object at once and then post them, the ID of the underlying object is not returned.
In this code fragment the TAfbeeldingen class is related to TEenheidlading (as you might have guessed).
EHL := TEenheidlading.Create;
try
EHL.code := 'ehl object';
EHL.afbeeldingid := TAfbeeldingen.Create;
EHL.afbeeldingid.omschrijving := 'afbeelding object';
ClientData.ClientConnectie.Client.Post(EHL);
finally
EHL.Free;
end;
Both objects are correctly saved to the database. Then the ID of the EHL class is returned ok, but the ID of the underlying TAfbeeldingen class is not. It's ID is in the database:
But is not returned: