Could not find a setter for property commenetauthoremail in class springMVC.NLoveB.po.Comments

Could not find a setter for property commenetauthoremail in class springMVC.NLoveB.po.Comments

写了一个实体类,在运行项目时出现如下错误

Caused by: org.hibernate.PropertyNotFoundException: Could not find a setter for property commenetauthoremail in class springMVC.NLoveB.po.Comments
	at org.hibernate.property.BasicPropertyAccessor.createSetter(BasicPropertyAccessor.java:246)
	at org.hibernate.property.BasicPropertyAccessor.getSetter(BasicPropertyAccessor.java:240)
	at org.hibernate.mapping.Property.getSetter(Property.java:328)
	at org.hibernate.tuple.entity.PojoEntityTuplizer.buildPropertySetter(PojoEntityTuplizer.java:416)
	at org.hibernate.tuple.entity.AbstractEntityTuplizer.<init>(AbstractEntityTuplizer.java:201)
	at org.hibernate.tuple.entity.PojoEntityTuplizer.<init>(PojoEntityTuplizer.java:80)
	... 49 more
出现这个错误,原因已经很简单了

提示说没有这个字段 commenetauthoremail  的set方法,或错误

添加好方法即可


如果您觉得本文章对您有用,也为了更好的运营博客,您可以点击这里捐助

评论 抢沙发

昵称 (必填) 邮箱 (必填)
表情