Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Many-to-many composite ID

 
Jonathan Huang
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there a way to map a many-to-many set that does not use the entire composite ID of the association.

Table1's PK = column1 + column2 + column3
Table2 only has column1 and column2 that associate to Table1.

For Example we have two mappings:





The code above throws a: "must have same number of columns as the referenced primary key (webquest.OTOSTLKPSCALE [JOB,SCLNAME,SCLPUNCH])" error.

Thanks in advance and I hope I was clear in describing my issue.
[ July 25, 2006: Message edited by: Jonathan Huang ]
 
Jonathan Huang
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anyone?

Still having trouble figuring this one out!

Thanks.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic