org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):

测试dao中的方法报错


报错信息:
org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):_第1张图片
dao:
org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):_第2张图片
Test:
org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):_第3张图片
配置文件:
org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):_第4张图片

出现这个错误的原因就是配置文件中mapper文件的路径写错了:
mybatis.mapper-locations=classpath:mapper/*.xml

目录中写的是mappers,文件中写的是mapper。

你可能感兴趣的:(bug)