-->
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: Map a formula in named query issue
PostPosted: Tue May 24, 2011 4:51 am 
Newbie

Joined: Tue May 24, 2011 4:16 am
Posts: 1
Hi, i'm new to nhibernate and i'm experiencing this issue:
i've a mapping file with this kind of properties derived from formulas
Code:
<property name="TypeOfPerson" formula="CASE KIND WHEN 198 THEN 0 ELSE 999 END" update="false" insert="false"/>
<property name="LanguageCultureName" formula ="CASE NAZ WHEN 'I' THEN 'it-IT' ELSE 'en-GB' END" update="false" insert="false"/>


When I attempt to load entity by id it works as I would expected but when i try to load a list from a named query i receive this error: "value cannot be null. Parameter name: fieldName".
If i omit the formulas all work fine.


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.