Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Association references unmapped class exception with hibernate

Shyam Gautam
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hii to all

actually i am a new to hybernate and during make projects i get this exception and after spending 2 more days i am not able to find why this exception is comes please suggest me .
because i knew this error is coming during the getseeion to the database to load the mapping file .

please check where is my mapping is wrong ?

exception is
org.hibernate.MappingException: Association references unmapped class: com.tra.Generate.TraCurrentUsers
at org.hibernate.cfg.HbmBinder.bindCollectionSecondPass(
at org.hibernate.cfg.HbmBinder$CollectionSecondPass.secondPass(
at org.hibernate.cfg.CollectionSecondPass.doSecondPass(
at org.hibernate.cfg.Configuration.secondPassCompile(
at org.hibernate.cfg.Configuration.buildSessionFactory(
at com.tra.manager.transaction.TransactionMngr.getSession(
at com.tra.manager.transaction.TransactionMngr.retrieveData(

i make my .hbm.xml and pojo by reverse enginnering i want to map usermaintenance table to the tracurrentusers and traroles

first .hbm file is

second one is

last third one is
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic