-->
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.  [ 3 posts ] 
Author Message
 Post subject: ANSI CASE statement in HQL
PostPosted: Wed Sep 29, 2004 9:50 am 
Newbie

Joined: Tue Jun 22, 2004 11:35 am
Posts: 10
Hi
i need to use CASE statement or DECODE is the select part of my query, is there any way to do this. the reason being that i need to return a diferent column depending on the value of another. I just get the undefined alias error when trying to use either. as we are using HQL for all other queries i don't want to have to use jdbc... any help would be greatly appreciated.

Hibernate version:
2.1.6


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 29, 2004 10:12 am 
Expert
Expert

Joined: Fri Feb 06, 2004 7:49 am
Posts: 255
Location: Moscow, Russia
Try to use Interceptors, http://www.hibernate.org/hib_docs/reference/en/html/manipulatingdata.html#manipulatingdata-interceptors

_________________
Leonid Shlyapnikov


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 29, 2004 10:17 am 
Expert
Expert

Joined: Fri Feb 06, 2004 7:49 am
Posts: 255
Location: Moscow, Russia
Or Lifecycle

_________________
Leonid Shlyapnikov


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.