一、发现问题
<select id="queryStudentByNum" resultType="student" parameterType="string"> select num,name,phone from student <where> <if test = " num!=null and num!='' "> AND num = #{num} </if> </where> </select> Mybatis查询传入一个字符串传参数,报There is no getter for property named 'num' in 'class java.lang.String'。<select id="queryStudentByNum"