摘要:
(1)思考: <select id="getUsersByParams" resultType="java.util.HashMap"> select id,username,password from user where username = #{name} </select> resultTy 阅读全文
摘要:
详细:https://blog.csdn.net/mrqiang9001/article/details/79520436 一个参数,但是是数组,必须加@Param 见梳理11 foreach元素 例子: 阅读全文
摘要:
map可以代替任何的实体类,所以当我们数据比较复杂时,可以适当考虑使用map来完成相关工作 1、写sql <select id="getUsersByParams" resultType="map"> select id,username,password from user where usern 阅读全文
摘要:
如果有索引,前面的%不要加 例子: 或者 阅读全文
摘要:
1、接口中添加注解 public interface AdminMapper { /** * 保存管理员 * @param admin * @return */ @Insert("insert into admin (username,password) values (#{username},#{ 阅读全文