I have 2 tables and shown below and I need to create 2 entity beans having CMR.
Table 1 SystemInfo (SystemID(PK), SystemName)
Table 2 SystemData(SystemID,SubSystemName,SubSystemLocation) PK (SystemID, SubSystemName) FK (SystemID) maps to SystemID in SystemInfo table.
Is this possible using CMR ? Can one field be in CMR as well as CMP fields sections ?
I am able to deploy CMR based beans if the dependent field is non primary key and is not in CMP fields section. This means that it will be additional field in child table.
I also tried to change the primary key of child table as PK (SystemID) and then put the SystemID field in both CMP field and CMR section. I always get "duplicate column name" error. In case 2 (with single PK) I turned on the trace and the SQL generated is