问题:
nested exception is org.hibernate.QueryException: Named parameter [3] not set
@Query(value = "select e from Entity e where e.param1 = ?1 and e.param3 = ?3 ")
Entity test(Long param1, Long param2, Long param3);
解决方式:
@Query(value = "select e from Entity e where e.param1 = ?1 and e.param3 = ?2 ")
Entity test(Long param1, Long param3, Long param2);
总结:
1.jpa索引参数 当有参数未使用 新增加参数不能跳数
2.更新同样