Jap update小例子
使用Jpa更新时:
@Transactional
@Modifying
@Query("update GuideScreenSyncMonitoring g set g.status = '1' where g.ip in(:ips)")
void updateStatusOffline(@org.springframework.data.repository.query.Param("ips") List<String> ips);
注意事项:@Param注解使用的是:org.springframework.data.repository.query.Param下的,如果@Param注解使用
的是:org.apache.ibatis.annotations.Param,则更新失败并报@Param注解的错。

浙公网安备 33010602011771号