-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Composite primary Key using FK refrences
PostPosted: Thu May 13, 2010 3:29 am 
Newbie

Joined: Mon Jun 22, 2009 3:14 am
Posts: 1
I have a table that has composite primary key, these two colums are FK references.

Table A
[ A_id PK
Desc ]

Table B
[ B_Id PK
Desc ]

Table A_B_Pemissiom
[
A_id (FK table A)
B_Id (FK table B)
PrimaryKey ( A_id,B_Id )
]


Can any one help me in writing the POJOS using annoations for this case.


Top
 Profile  
 
 Post subject: Re: Composite primary Key using FK refrences
PostPosted: Sat May 15, 2010 11:23 am 
Newbie

Joined: Fri May 14, 2010 5:51 pm
Posts: 8
Check out this tutorial:
http://jpa.ezhibernate.com/Javacode/learn.jsp?tutorial=15usingcompoundprimarykeys

Maybe can help you ;)

Irshad


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.