-->
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: many-to-one mapping error
PostPosted: Mon Jul 16, 2007 12:56 pm 
Newbie

Joined: Mon Jul 02, 2007 8:45 am
Posts: 19
Hi all!

If i put the lines:

<many-to-one name="Salidemn" column="SALIDEMN" class="MapeamentoOR.Salminat,MapeamentoOR" />
<many-to-one name="Sagidest" column="SAGIDEST" class="MapeamentoOR.Sagcdstt,MapeamentoOR" />


This error message is displayed:

System.InvalidCastException: Specified cast is not valid.

But when i change it to:

<property column="SALIDEMN" type="Decimal" name="Salidemn" />
<property column="SAGIDEST" type="Decimal" name="Sagidest" />

The error message is not displayed.

Why?


I have a gridview that displays the Location(SALIDEMN) and the Status(SAGIDEST).

I need to link the description fields to its current pks.

SALIDEMN = 1: Ore Mine 1

Status = 2: Active

Could someone help me on it?

Regards,


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.