build/classes/edu/jmi/mapper/UserMapper.xml
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="edu.jmi.dao.UserDao">
<resultMap id="BaseResultMap" type="edu.jmi.model.User">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="account" jdbcType="VARCHAR" property="account" />
<result column="pwd" jdbcType="VARCHAR" property="pwd" />
<result column="uname" jdbcType="VARCHAR" property="uname" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="sex" jdbcType="VARCHAR" property="sex" />
<result column="createTime" jdbcType="VARCHAR" property="createTime" />
</resultMap>
<select id="selectAll" parameterType="edu.jmi.model.User" resultMap="BaseResultMap">
select * from user
order by id asc
</select>
<select id="findByAccount" parameterType="edu.jmi.model.User" resultMap="BaseResultMap">
select * from user where account=#{account}
</select>
<select id="findByUname" parameterType="edu.jmi.model.User" resultMap="BaseResultMap">
select * from user where uname=#{uname}
</select>
<select id="findById" parameterType="edu.jmi.model.User" resultMap="BaseResultMap">
select * from user where id=#{id}
</select>
<insert id="insert" parameterType="edu.jmi.model.User" >
insert into user (account,uname, pwd,type,
sex, createTime
)
values (#{account,jdbcType=VARCHAR},#{uname,jdbcType=VARCHAR}, #{pwd,jdbcType=VARCHAR},
#{type,jdbcType=VARCHAR}, #{sex,jdbcType=VARCHAR}, #{createTime,jdbcType=VARCHAR}
)
</insert>
<update id="update" parameterType="edu.jmi.model.User">
update user set
account = #{record.account,jdbcType=VARCHAR},
uname = #{record.uname,jdbcType=VARCHAR},
pwd = #{record.pwd,jdbcType=VARCHAR},
sex = #{record.sex,jdbcType=VARCHAR},
type = #{record.type,jdbcType=VARCHAR}
where id=#{id}
</update>
<update id="updatePwd" parameterType="edu.jmi.model.User">
update user set
pwd = #{record.pwd,jdbcType=VARCHAR}
where account=#{account}
</update>
<delete id="delete" parameterType="java.lang.Integer">
delete from user
后面还有 5 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。