天天看点

MyBatis报错 Parameter '0' not found. Available parameters are [arg1, arg0, param1, param2]

修改
<update id="updateStatusById" parameterType="java.lang.Integer">    
        update  
        nic_techsupport  
        set status_id = #{0}  
        where techsupport_id =#{1}  
    </update>  
为
<update id="updateStatusById" parameterType="java.lang.Integer">    
        update  
        nic_techsupport  
        set status_id = #{arg0}  
        where techsupport_id =#{arg1}  
    </update>  
在MyBatis3.4.4版不能直接使用#{0}要使用 #{arg0}      

 参考:https://www.cnblogs.com/EasonJim/p/7056256.html

转载于:https://www.cnblogs.com/YLQBL/p/7904108.html