-->
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: inheritance design issues
PostPosted: Thu Jun 11, 2009 11:22 am 
Beginner
Beginner

Joined: Sun Aug 22, 2004 5:32 pm
Posts: 40
Hello,

I am using hibernate 3.2, and oracle 9.2.2.

I am having some issues and not sure the best approach to take.

I was interested in using the table per hierarchy design for an application. However, the tables are already written and the field constraints are all set to not null. Thus, this approach will not work for me. I am not sure what approach to take now.

My application structure is as follows:
CLASSXInt - interface
ClASSA - attribs: X, Y, Z - implements CLASSXInt
CLASSB - attribs: A, B, C - extends CLASSA
CLASSC - attribs: E, F, G - extends CLASSB

This structure cannot change.

One table (TABLE123) is used for most of the data contained in all the classes. What I mean by "most", is that one field in TABLE123 is reference data for the data in another table (TABLE456). In other words, I need to pull the value of TABLE123, then use it to get the actual meaningful data from TABLE456.

The constraints on all of the fields in both tables is set to NOT NULL and cannot be changed. What is the best approach to setting up hibernate to work with this situation? Thanks.

I need to be able to do full CRUD on CLASSA, CLASSB, and CLASSC.

_________________
Scott
www.HikeHaven.com


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.