mappingResources couldn't find the mapping file

209 Views Asked by At

I have my hibernate configuration files locate under a resources/hibernate directory folder. resources diretory folder is a source folder. When I declare mappingResources in Spring configuration like this:

<property name="mappingResources">
   <list>
      <value>classpath:hibernate/PojoA.hbm.xml</value>
   </list>
</property>

I got an error mention that PojoA.hbm.xml doesn't exists. May I know how this can be fix?

1

There are 1 best solutions below

0
zdesam On BEST ANSWER

Try this one

<property name="mappingResources">
   <list>
      <value>hibernate/PojoA.hbm.xml</value>
   </list>
</property>