Greetings,

I have a table Access_Permission that _has_ relation 1-* to
Access_Schedule.

This table Access_Permission has two attributes (uniques), A1 and A2,
that would be the foreign keys of the table Access_Schedule.

Access_Permission                       Access_Schedule
-----------------                       ---------------
A1                      -- 1-N -->      A1
A2                                      A2
...                                     ...
(A1,A2) UNIQUE                          (A1,A2) FK

These tables are mapped in two entity beans (CMP). The Access_Schedule
bean has no primary keys, only foreign keys. I defined a relationship
between them (access_permission_schedule), but I'm getting this error
when deploying the beans:

"
 Atleast one role of a foreign-key mapped relationship must have key
fields (or <primkey-field> is missing from ejb-jar.xml):
ejb-relation-name=access_permission_schedule]
"

I'm using xdoclet to generate the descriptors and this is the entry of
my relation on Access_Permission bean:

 /** 
     * @ejb.relation
     *  name="access_permission_schedule"
     *  role-name="X1"
     *  cascade-delete="no"
     *  target-ejb="AccessSchedule"
     *  target-role-name="X2"
     * @ejb.interface-method
     *  view-type="local"
     * @ejb.transaction
     *  type="Supports"
     */
    public abstract java.util.Collection getSchedule();

Any comments are welcome!

thanks,
Pedro Salazar.
-- 
-PS

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to