-->
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: pb association one to one
PostPosted: Fri Jul 04, 2008 8:08 am 
Newbie

Joined: Tue Jun 24, 2008 6:42 am
Posts: 19
Bonjour, j'ai une association one to one entre deux classes,
voici le mapping :

-Dans le mapping de la classe Node
Code:
<one-to-one name="validity" class="Hibernate.Validity" cascade="all"/>

-Dans le mapping de la classe validity
Code:
<one-to-one name="node" class="Hibernate.Node" property-ref="validity" />


Le session.save() fonctionne très bien en cascade , par contre le session.load() ne fonctionne pas du tout, auriez vous une idée, merci[/code]

l'erreur est could not load an entity: [Hibernate.Node#1]
Caused by: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).

je peux charger un objet quand je n'ai qu'une seul association one to one dans le fichier xml de la classe de cet objet et si je met plusieurs balise one to one la ça ne marche plus...


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 07, 2008 4:24 am 
Newbie

Joined: Tue Jun 24, 2008 6:42 am
Posts: 19
j'ai enlevé les property-ref et maintenant ça fonctionne, arf


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.