-->
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: IDBAG with two relations
PostPosted: Thu Aug 16, 2007 3:09 am 
Beginner
Beginner

Joined: Mon Jul 30, 2007 4:58 pm
Posts: 21
Here's my domain model:
A User has many Transactions. A Portfoilo also has many Transactions. The relations are one to many and unidirectional. Traversing from Transaction to a User or Portfoilo is unnecessary. Transaction table has two foreign keys to each of the User and Porfoilo Table.

The problem is I am trying to make the mapping as IDBAG. (Since BAGs are not nice when inverse = false). My question is :

Is it safe to use the PK of Transaction table to use as a surrogate key for both of the User and Portfoilo IDBAG mappings ?


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.