Error while creating hibernate session factory bean

Error Text:
Invocation of init method failed; nested exception is org.hibernate.InvalidMappingException: Could not parse mapping document from input stream

There are two probable reasons for this situation in my experience. Some of them are as follows

1. The "id" is not present in one or more mapping files (hbm.xml)

2. The DTD definition may be wrong, try replacing following with later.

<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">


<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"> 

Comments

Popular posts from this blog

Caused by: java.sql.SQLTimeoutException: ORA-01013: user requested cancel of current operation

pandas dataframe add missing date from range in a multi-dimensional structure with duplicate index

Delete horizontal, vertical and angled lines from an image using Python to clear noise and read text with minimum errors