-->
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: Can Hibernate do column value transforms?
PostPosted: Tue May 18, 2004 11:18 am 
Newbie

Joined: Tue May 18, 2004 10:47 am
Posts: 5
Hello and thanx for any help you can offer.
I am conducting an evaluation of Hibernate for possible inclusion in the
refactoring of an existing app. I am current using version 2.1.3.
My question concerns table column values and their transformation/conversion.
The current application queries the database and produces DTOs from the result set. The values of certain columns in a row in the result set are transformed/converted to different values in the DTO based on application context business rules.
My question is:
Does Hibernate have any facility for handling this type of conversion or do I continue to do this conversion after the object graph is returned from a Hibernate query?

Thanx again!


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 18, 2004 12:35 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
1. use attribute formula
2. use custom type
3. (my favorite), do the business rules on an unmapped getter

_________________
Emmanuel


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.