-->
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: Query with null criteria
PostPosted: Fri Apr 02, 2004 12:33 pm 
Regular
Regular

Joined: Thu Feb 05, 2004 6:51 am
Posts: 50
Hi all,

I'd like to know how I could build a query with this API :
String pId = null;
Query qApplicationMapQuery = session.createQuery(rom HibernateApplicationMap appMap where appMap.packageId = :keyValueParam_1);
qApplicationMapQuery.setString("keyValueParam_1", pId);

The equivalent in SQL is "where packageId is null " ?

Vlad


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 02, 2004 12:40 pm 
Regular
Regular

Joined: Thu Feb 05, 2004 6:51 am
Posts: 50
I know this is possible with a query in sql langage if this is not a onetoone relation but I want to use the API I have used.

Vlad


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.