随笔分类 - mybatis
摘要:https://www.cnblogs.com/bingsying/p/12507419.html 1 WarehouseItem warehouseItem = warehouseItemService.getById(2117733125); 2 UpdateWrapper<WarehouseI
阅读全文
摘要:https://www.cnblogs.com/summerday152/p/13874936.html
阅读全文
摘要:https://www.jianshu.com/p/ceb1df475021 https://baomidou.com/
阅读全文
摘要:Mapper.xml文件中的namespace与mapper接口的类路径相同。 Mapper接口方法名和Mapper.xml中定义的每个statement的id相同 Mapper接口方法的输入参数类型和mapper.xml中定义的每个sql 的parameterType的类型相同 Mapper接口方
阅读全文
摘要:如果写成'%#{name}%' ,就会报错Parameter index out of range 1.表达式: name like "%"#{name}"%" 2.表达式: name like '%${name}%' 有注入 3. 表达式: name like concat(concat('%',
阅读全文
摘要:public interface UserMapper{ String getNameByUserId(@Param("userId") String userId); } 当我们传入userId="34;drop table user;"后 <select id="getNameByUserId"
阅读全文
摘要:一、创建一个类注入PaginationInterceptor @Configuration public class MybatisPlusConfig { /** * 分页插件 */ @Bean public PaginationInterceptor paginationInterceptor(
阅读全文