Hibernate version:2.1.8
How can I map a foregin key constraint with multiple columns?
I have a table report_field with a primary key of two columns (report_def_id and column_id) which itself are foreign keys. Than I have a table function with a primary key of two columns (function, report_def_id and column_id). So the primary_key of one table is contained in the primary key in the other table and is a foreign key.
This is how the table structure looks like:
function
---------
PK,FK1 report_def_id
PK,FK1 column_id
PK function
.
.
.
report_field
-------------
PK,FK2 report_def_id
PK,FK3 column_id
.
.
.
Thank you very much for your help!
|