-->
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: Can I map two classes to one table
PostPosted: Tue Mar 23, 2004 12:34 pm 
Beginner
Beginner

Joined: Tue Sep 09, 2003 5:28 pm
Posts: 33
Location: Cincinnati, OH
Hi all,

I am using Hibernate 2.1 the latest version, and my database is IBM AS/400.

I have a table called matter, which has a lot of columns, for cache reason, I only need some of its columns, and the primary keys are three fields, I am using composite-id, which works fine. But then, I want to add some columns for cache with different key (just one column this time) than before, and also want to keep the previous one. Anyone knows how to handle this kind of situation?

What I am thinking about it is, to create another new class and let it map to the same table, haven't tried this yet. (two classes map to one same table)

And also I don't know if I can use the previous class with two different keys? Seems not working. :(

Anyone has any ideas are so thankful!


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.