-->
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.  [ 1 post ] 
Author Message
 Post subject: Creating annotations mapping class for this scenario...
PostPosted: Thu May 17, 2007 6:14 pm 
Newbie

Joined: Thu May 03, 2007 6:24 pm
Posts: 14
Pls help me to create the mapping classes in annotations for the following scenario.

I have four tables A,B,C,D

TABLE A{
id,
foreign_ key_id
foreign_ key_id_Type
}

'foreign_key_id' in table A is a primary key of table B/C/D.
From 'foreign_ key_id_Type' in TABLE A, we can say to which table(among B,C and D) foreign_key_id of table A is referring .
i.e
if foreign_ key_id_Type="B", then foreign_ key_id refers a record in TABLE B
if foreign_ key_id_Type="C", then foreign_ key_id refers a record in TABLE C
if foreign_ key_id_Type="D", then foreign_ key_id refers a record in TABLE D


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

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.