-->
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: criteria: add additional user defined column in output
PostPosted: Sat Mar 19, 2005 4:39 pm 
Regular
Regular

Joined: Thu Dec 11, 2003 4:14 pm
Posts: 86
Location: Hibernate 3 + annotations, Oracle 9i, PostgreSQL 8.0, Java 1.5.0
I would like to know if someone managed to add a user defined column in query output with the criteria-api.

I do have a table and would like to call a database function which do some calculation - some sort of:

select item.*, calculate_price(item.itemId) as price from items

For the "item" exists a pojo, but the price is a dynamic column and the function might change depending on the current use.


Thanks!

Hibernate version:

hibernate 3 cvs 2005-03-18
annotations cvs 2005-03-18


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.