Mapped Statements collection already contains value for
程序员文章站
2022-07-15 12:05:28
...
前言
启动报错
Caused by: java.lang.IllegalArgumentException: Mapped Statements collection already contains value for com.picc.dao.HolidayArrayMapper.findHolidayByDate. please check com/picc/dao/HolidayArrayMapper.java (best guess) and com/picc/dao/HolidayArrayMapper.java (best guess)
原因
报错说的很明确
出现了两个相同方法 findHolidayByDate
复制忘记改了 以为不同参数不影响
//区间查询
@Select("select count(1) form holiday_array where holiday_date between #{start} and #{end} ")
int findHolidayByDate(@Param("start") String start,@Param("end") String end);
//单日查询
@Select("select count(1) form holiday_array where holiday_date =#{date} ")
int findHolidayByDate(@Param("date") String date);
推荐阅读
-
使用mybatis报错【Result Maps collection already contains value for ...BaseResultMap】的解决方法
-
moven 部署Sping与mybatis时,Mapped Statements collection does not contain value for Xxxxxxxx
-
【Bug解决】org.apache.ibatis.type.TypeException: The alias ‘xxxx‘ is already mapped to the value ‘xxx‘
-
java.lang.IllegalArgumentException: Result Maps collection already contains value for
-
Cause: java.lang.IllegalArgumentException: Result Maps collection already contains value for ...
-
mybatis****Caused by: java.lang.IllegalArgumentException: Result Maps collection already contains va
-
java.lang.IllegalArgumentException: Result Maps collection already contains value for
-
Cause: java.lang.IllegalArgumentException: Result Maps collection already contains value for.....
-
解决:Cause: java.lang.IllegalArgumentException: Result Maps collection already contains value for xxx
-
Cause: java.lang.IllegalArgumentException: Result Maps collection already contains value for……