I am just learning Spring3 Validation with Hibernate. I have this class but I am setting getting the following error
org.hibernate.MappingException: Unknown entity: com.stutteringjohnsmith.model.Friend
I am doing the sample from
http://www.roseindia.net/tutorial/spring/spring3/web/spring-3-mvc-and-hibernate3-example-part1.html
but I change the Article to Friend! Please help me out
The most likely problem is that there is still a reference to the "Article" in the code that has not been updated to "Friend". I would try searching all the files for "Article" and update as required. Have you changed the <property name="annotatedClasses">
section in the dispatcher-servlet.xml
file for example?
Also you might want accept answers to your questions otherwise it might put people off helping you out!
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.