在使用hibernate中出现以下错误以及解决方法
Caused by: org.dom4j.DocumentException: http://hibernate.org/dtd/hibernate-mapping-3.0.dtd%20 Nested exception: http://hibernate.org/dtd/hibernate-mapping-3.0.dtd%20
解决如下:*.hbm.xml中 “http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd “>最后多了空格,删除即可。
Caused by: org.hibernate.DuplicateMappingException: Duplicate class/entity mapping db.domain.DUser
解决如下:在hibernate.cfg.xml中添加
<property name="javax.persistence.validation.mode">none</property>
INFO: HHH000424: Disabling contextual LOB creation as createClob() method threw error : java.lang.reflect.InvocationTargetException
解决如下:在hibernate.cfg.xml中添加
<property name="hibernate.temp.use_jdbc_metadata_defaults">false</property>