Win a copy of Machine Learning Systems: Designs that scale this week in the Scala forum
or Xamarin in Action: Creating native cross-platform mobile apps in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Hibernate query help  RSS feed

 
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a situation where I need to check values against null. I have three columns(declared as NUMBER in database) need to write a select query in hql. I was trying set query strings some times there will be null value when there is a null value it throws me null pointer exception.

please help me in this.

Thanks,
 
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you please update the code snippet?
 
jaisai vijay
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Here is the sample code and I declare id2 and id3 as null here for example some times there might be a value but my problem is in this scenario


Please help me to solve this issue.
 
WARNING! Do not activate jet boots indoors or you will see a tiny ad:
Rocket Oven Kickstarter - from the trailboss
https://coderanch.com/t/695773/Rocket-Oven-Kickstarter-trailboss
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!