Hibernate - PropertyNotFoundException: Could not find a getter for

后端 未结 10 1710
一个人的身影
一个人的身影 2020-12-10 13:53

I have a class that looks like the following:

public class MyClass {
    private String dPart1;

    public String getDPart1() {
        return dPart1;
    }         


        
10条回答
  •  攒了一身酷
    2020-12-10 14:11

    The naming convention of the property matters example in my own case I initially used

    private String newimsi, getNewImsi();
    

    the above failed with same exception

    propertynotfoundexception

    until I corrected to below before it worked

    getNewimsi();
    

提交回复
热议问题