-->
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: Mapping without primary key
PostPosted: Thu Oct 21, 2004 3:27 am 
Newbie

Joined: Thu Oct 21, 2004 3:18 am
Posts: 1
Hi

I have an Oracle 9 table without primary key. is it possible to do the mapping to a class in the hibernate.cfg.xml file? and how?. Can you give me an example, please?

Regards

Maria


Top
 Profile  
 
 Post subject:
PostPosted: Thu Oct 21, 2004 3:29 am 
Hibernate Team
Hibernate Team

Joined: Thu Dec 18, 2003 9:55 am
Posts: 1977
Location: France
id = unicity
if you table doesn't have primary key but rows are unique, find how you define the unicity.
Then use it with a composite id
If row can be duplicated... you cannot use hibernate.

In hibernate in action identity is very very well explained

_________________
Anthony,
Get value thanks to your skills: http://www.redhat.com/certification


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.