Win a copy of Kotlin in Action this week in the Kotlin forum!
    Bookmark Topic Watch Topic
  • New Topic

hibernate is giving following exceptions: could not load and could not execute query  RSS feed

ganesh vinayaka
Posts: 4
  • Mark post as helpful
  • send pies
  • Report post to moderator
posted September 26, 2005 06:13 AM

I am using hibernate in my jsf application. I use a method which
executes Query returned from session.createQuery(here query is typed)
and i will run the Iterator of java.util package.

Now the problem is if i call this from one jsf page it is working
very well. when i call the same method from another jsf page it is giving
two exceptions as follows:


Hibernate: select questionse0_.questionId as questionId0_, questionse0_.question as question0_, questionse0_.optionOne as optionOne0_, questionse0_.optionTwo as optionTwo0_, questionse0_.optionThree as optionTh5_0_, questionse0_.optionFour
as optionFour0_, questionse0_.answer as answer0_, questionse0_.subjectId as subjectId0_, questionse0_.seniorityId as seniorit9_0_, questionse0_.averageTime as average10_0_, questionse0_.answerWeightage as answerW11_0_ from questions questionse0_ where questionse0_.questionId=?
net.sf.hibernate.exception.JDBCConnectionException: could not load: [com.kb.bean.QuestionSet#2]
at net.sf.hibernate.exception.SQLStateConverter.convert(


Hibernate: select questionse0_.questionId as x0_0_ from questions questionse0_ where (questionse0_.subjectId=? )and (questionse0_.seniorityId=? )and
(questionse0_.questionId in(? , ? , ? , ? , ? , ? , ?))
net.sf.hibernate.exception.JDBCConnectionException: Could not execute query
at net.sf.hibernate.exception.SQLStateConverter.convert

Remember that Query is working in one instance and in the second it is giving above exceptions.
can any one do favour for this? It will be appreciated.

Gregg Bolinger
Ranch Hand
Posts: 15304
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please do not post the same question in multiple forums and multiple times in the same forum. It just makes it harder to help you and wastes everyone's time. Please continue discussion in this thread.
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!