关于An association from the table XX refers to an unmapped class错误
Posted 昵称是默默呐
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了关于An association from the table XX refers to an unmapped class错误相关的知识,希望对你有一定的参考价值。
1.检查*.hbm.xml里面类全名
2.检查*.hbm.xml文件名是否正确(自己文件名由于copy 丢失hbm)
3.检查hibernate.cfg.xml文件中的相关联的两个<mapping resource=""/>的顺序,可能有其中一个需要引用另一个,但是另一个却还没有编译,就是说被用作外键的表要放在前面
4.检查hibernate.cfg.xml文件中是否添加了<mapping resource="xxxxx.hbm.xml"/>
我的错误:是因为未加载关联的实体 在application.xml文件中加入关联的模块jar包,顺序在关联的jar之前
<property name="mappingJarLocations"> <list> <value>WEB-INF/lib/process-workflow-bundle-4.0.0-SNAPSHOT.jar</value> <value>WEB-INF/lib/operation-4.0.0-SNAPSHOT.jar</value> </list> </property>
以上是关于关于An association from the table XX refers to an unmapped class错误的主要内容,如果未能解决你的问题,请参考以下文章
Linq------错误: Unable to determine the principal end of an association between the types
The prefix "p" for attribute "p:message" associated with an element type "b
[Functional Programming] Randomly Pull an Item from an Array with the State ADT (Pair)
Creating an archive from a directory without the directory name being added to the archive
An unexpected error prevented the server from fulfilling your request. (HTTP 500)
An unexpected error prevented the server from fulfilling your request. (HTTP 500)