• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate - SQLGrammarException

 
Parameswaran Thangavel
Ranch Hand
Posts: 485
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi when i am trying to get some values i am getting the exception




the exception i get is
net.sf.hibernate.exception.SQLGrammarException: Could not execute query

can any one explain me where i am was wrong.

teh code was taken from the net.
 
Sebastian Hennebrueder
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you should post the complete stack trace, your db name, hibernate.cfg.xml. The field name could be wrong, the Dialect you configured or anything else.

Best Regards Sebastian
 
Parameswaran Thangavel
Ranch Hand
Posts: 485
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi Sebastin

Thanks for your reply.

I solved the problem, i am using DB2 as my back end the problem is with the wrong schema is used when referring to the table.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic