hibernate.cfg.xml not found

前端 未结 7 2127
野的像风
野的像风 2020-12-06 05:46

I am new to Hibernate, reading this book \"Java persistence with Hibernate\" and I am trying to implement the example from there. So far my Ant build is successful, but when

7条回答
  •  悲哀的现实
    2020-12-06 06:09

    Your hibernate.cfg.xml needs to be inside the src directory; otherwise it's not covered by Ant's copymetafiles target, so it won't end up in your compiled classpath.

提交回复
热议问题