Hi,
I have two entities:
[Entity] [Table('LOTEAMENTO')] [Sequence('GEN_LOTEAMENTO_ID')] [Id('FID', TIdGenerator.IdentityOrSequence)] TLOTEAMENTO = class private [Column('ID', [TColumnProp.Required])] FID: Integer; [Column('NOME', [], 100)] FNOME: Nullable<string>; public property ID: Integer read FID write FID; property NOME: Nullable<string> read FNOME write FNOME; end;
[Entity]
[Table('QUADRA')]
[Sequence('GEN_QUADRA_ID')]
[Id('FID', TIdGenerator.IdentityOrSequence)]
TQUADRA = class
private
[Column('ID', [TColumnProp.Required])]
FID: Integer;
[Column('NOME', [], 50)]
FNOME: Nullable<string>;
[Association([TAssociationProp.Lazy],CascadeTypeAll - [TCascadeType.Remove])]
[JoinColumn('ID_LOTEAMENTO', [], 'ID')]
FID_LOTEAMENTO: Proxy<TLOTEAMENTO>;
function GetID_LOTEAMENTO: TLOTEAMENTO;
procedure SetID_LOTEAMENTO(const Value: TLOTEAMENTO);
public
property ID: Integer read FID write FID;
property NOME: Nullable<string> read FNOME write FNOME;
property ID_LOTEAMENTO: TLOTEAMENTO read GetID_LOTEAMENTO write SetID_LOTEAMENTO;
end;
How should that entity be mapped to when adding a <Tquadra> also does not insert a <TLoteamento>?
Thanks,