mapper.xml映射文件

<?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="com.mapper.StudentMapper">//映射类
	<select id="queryStudentByIdWithConverter" parameterType="int" resultType="studentResult">//parameterType输入参数类型;resultType返回参数类型
		select * from student where id=#{id}//sql语句
	</select>
	 
</mapper>

关于

发布了16 篇原创文章 · 获赞 0 · 访问量 233

猜你喜欢

转载自blog.csdn.net/BTLA_2020/article/details/105171685