Mybatis错误:Parameter 'XXX' not found. Available parameters are [1, 0, param1, param2]

Mybatis错误:Parameter 'XXX' not found. Available parameters are [1, 0, param1, param2]

缘由:传递的参数超过一个html

ui

解决办法:spa

(1)直接把值改为数字.net

1code

2orm

3htm

<select id="LoginUser" parameterType="String" resultMap="userMap">blog

  SELECT * FROM user where emplnumb = #{0} and password=#{1}ci

</select>get

(2)在变量上加注解@Param

1

Public User selectUser(@param(“userName”) String name,@param (“userpassword”)

  

1

public List<user> getUserInformation(@Param("user") User user);

 

https://www.cnblogs.com/durui/p/8279117.html

https://blog.csdn.net/smile_from_2015/article/details/52199446 

相关文章
相关标签/搜索