org.apache.ibatis.type.TypeException: Could not set parameters for mapping: ParameterMapping{property=‘title’, mode=IN, javaType=class java.lang.String, jdbcType=null, numericScale=null, resultMapId=‘null’, jdbcTypeName=‘null’, expression=‘null’}. Cause: org.apache.ibatis.type.TypeException: Error setting non null for parameter #3 with JdbcType null . Try setting a different JdbcType for this parameter or a different configuration property. Cause: java.lang.ClassCastException: java.lang.Long cannot be cast to java.lang.String
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
id加注解即可
版权声明:本文为wenbin516原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。