• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Struggling with simple Hibernate Query

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey everybody,

this is my very first post at JavaRanch. I'm reading here now since I started with Java (around a year ago) and always found a way to solve my problems by myself or by searching.

Ok, I'm trying to do my very first steps in ORM with Hibernate. I want to combine stateless session beans (mainly to learn how to deal with lomboz) with Hibernate as a persistence layer. Till yesterday I was running with hibernate2.x, but I decided to migrate to hibernate3 today because of some nice new features and since I have to learn it anyway...why don't start with the modern release.

Here's my hbm.xml:



My hibernate.cfg.xml:



And here's the method from my ejb, which is currently now working. It looks ugly since I'm adding and rewriting the code since hours to get it work:



It works fine, but I had to install ANTLR to get it running. Could anyone tell me, why this simple createQuery needs ANTLR and why it is neither mentioned in any tutorial I found nor in the documentation on hibernate.org?

And what do you experienced guys think about the combination of stateless session beans (and for sure all the other J2EE stuff if needed) and hibernate?

Thanks a lot in advance guys! Hope my questions are not to stupid.
Cheers,
Thomas
[ March 29, 2005: Message edited by: Thomas Becker ]
 
A "dutch baby" is not a baby. But this tiny ad is baby sized:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic