原文:mybatis-plus樂觀鎖報Parameter ‘MP_OPTLOCK_VERSION_ORIGINAL‘ not found. Available parameters are [param1]

根據mybatis plus 官網文檔配置樂觀鎖,報如下錯誤 經過排查發現是因為樂觀鎖插件引起的,因為mybatis plus版本升級造成老版本配置方式不生效 public class MybatisPlusConfig 注冊樂觀鎖插件 Bean public OptimisticLockerInnerInterceptor optimisticLockerInnerInterceptor re ...

2021-11-24 11:38 0 1726 推薦指數:

查看詳情

Mybatis異常 -- Parameter 'XXX' not found. Available parameters are [1, 0, param1, param2]

這是mybatis多參數傳值,導致的錯誤。 如圖是我的Mapper和對應的xml(正確的配置) 因為mapper方法中,傳遞多個參數。沒有帶注解,導致出現如題異常。 總結:Mapper方法中,傳入多個參數,有多處理方式。 這篇博客總結挺好:MyBatis傳入多個參數的問題 ...

Fri Nov 01 17:31:00 CST 2019 0 327
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM