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: HBM Property Formula Quote
PostPosted: Fri Jun 06, 2008 7:06 pm 
Newbie

Joined: Fri Jun 06, 2008 6:40 pm
Posts: 1
Hi,
In my hbm file, I have a property:

<property
name="abcd"
type="java.lang.String"
update="false"
insert="false"
formula="(select ug.ts_name from ts_map um join ts_groups ug on ug.ts_id = um.ts_group_id where um.ts_delete = false)"
lazy="true"
not-null="false"
/>


The where clause in my formula ... i need to set it to the boolean value false. Do I use quotes around it? Single? Double?

Should it be:

formula="(select .... where um.ts_delete = 'false')"

or

formula="(select .... where um.ts_delete = "false")"

or no quotes?

formula="(select .... where um.ts_delete = false)"


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 17, 2008 1:34 am 
Beginner
Beginner

Joined: Sat Nov 19, 2005 11:54 am
Posts: 22
just use
formula="(select ug.ts_name from ts_map um join ts_groups ug on ug.ts_id = um.ts_group_id where um.ts_delete = 'Y')"


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.