解决办法, 再大dao的实现类上添加注解: @Transactional(readOnly = false ) 不让它只读就行了 转载于:https://www.cnblogs.com/shiwanming/p/9746737.html