错误:

org.apache.ibatis.binding.BindingException: Type interface com.kuang.dao.UserDAO is not known to the MapperRegistry.

错误:

java.lang.ExceptionInInitializerError

原因1:没有添加mappers

原因2:手动添加

<build>
<resources>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
<filtering>true</filtering>
</resource>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
<filtering>true</filtering>
</resource>
</resources>
</build>

记住这个错误org.apache.ibatis.binding.BindingException: Type interface com.kuang.dao.UserDAO is not known to the MapperRegistry.的更多相关文章

  1. Exception in thread "main" org.apache.ibatis.binding.BindingException: Type interface com.test.bean.groupMapper is not known to the MapperRegistry.

    Exception in thread "main" org.apache.ibatis.binding.BindingException: Type interface com. ...

  2. 报错org.apache.ibatis.binding.BindingException: Type interface com.atguigu.mybatis.bean.dao.EmployeeMapper is not known to the MapperRegistry.

    报错org.apache.ibatis.binding.BindingException: Type interface com.atguigu.mybatis.bean.dao.EmployeeMa ...

  3. MyBatis—— org.apache.ibatis.binding.BindingException: Type interface com.web.mybatis.i.PersonMapper is not known to the MapperRegistry.

    报错信息: Exception in thread "main" org.apache.ibatis.binding.BindingException: Type interfac ...

  4. org.apache.ibatis.binding.BindingException: Type interface XXX is not known to the MapperRegistry.

    动态代理因为namespace的地方写错了

  5. MyBatis典型的错误org.apache.ibatis.binding.BindingException: Invalid bound statement (not found)

    XXXmapper.java(接口) XXXmapper.xml(结果集映射) //此两个文件要在统一包下,且xml中的namespace是唯一的,为了区分须写成 该xml的全路径

  6. mybatis运行出现org.apache.ibatis.binding.BindingException

    今天学习mybatis的第一天,发现用junit测试报出了次异常:org.apache.ibatis.binding.BindingException: Type interface cn.dzp.d ...

  7. org.apache.ibatis.binding.BindingException: Mapper method 'attempted to return null from a method with a primitive return type (long).

    一.问题描述 今天发现测试环境报出来一个数据库相关的错误 org.apache.ibatis.binding.BindingException: Mapper method 'attempted to ...

  8. springboot2 中Druid和ibatis(baomidou) 遇到org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.iflytek.pandaai.service.multi.mapper.TanancyMapper

    调用mapper中任何方法都会出现类似的错误 org.apache.ibatis.binding.BindingException: Invalid bound statement (not foun ...

  9. 解决 org.apache.ibatis.binding.BindingException: Invalid bound statement (not found) 以及MyBatis批量加载xml映射文件的方式

    错误 org.apache.ibatis.binding.BindingException: Invalid bound statement (not found) 的出现,意味着项目需要xml文件来 ...

  10. org.apache.ibatis.binding.BindingException

    1.异常提示: org.apache.ibatis.binding.BindingException: Mapper method 'com.artup.dao.WorksDao.selectWork ...

随机推荐

  1. Linux的top命令原理简单了解

    top命令描述机器的cpu.内存等状态信息. 每3s刷新一次. 是procps工具集中的一个,该工具集还包括free.ps等等 top命令的代码实现逻辑是:由内核动态生成一个伪文件系统,提供一个内核状 ...

  2. 正确处理iOS从下方滑出滚动视图

    本文提供 Demo下载 在iOS 11开始,从最早的地图应用到最近的捷径,陆续有系统应用使用从下方滑出列表的形式,这种系统提供的圆角风格视图用手势划出和隐藏时非常自然流畅.国内的一些应用也跟进了这种交 ...

  3. springcloud(八) - 分布式事务seata

    术语 TM(transaction manage)事务管理器: 分布式事务的发起和终结者,负责提交和回滚全局事务. TC(transaction coordinatorr)事务协调器: 协调全局事务和 ...

  4. Qt 字符串相等判断问题

    QString str = "0"; if (QString(param.value.data()) == QStringLiteral("空")) { str ...

  5. 在CentOS 7.4下配置VNC Server服务

    安装步骤 1. 查询系统是否安装vnc-server [root@localhost ~]# rpm –qa | grep vnc 如果有返回值,类似于vnc-server-的值,说明已经安装了vnc ...

  6. 230219 Business 31-48

    31.  31: Maternity LeaveVeronica, when is your baby due?Next month.Are you going on maternity leave? ...

  7. maven静态资源过滤

    <resources> <resource> <directory>src/main/java</directory> <includes> ...

  8. springboot集成Thumbnailator压缩图片

    一.参考大神博客 1.https://blog.51cto.com/u_11269274/5118649 2.https://blog.csdn.net/weixin_44722978/article ...

  9. 为什么常用Formdata对象来上传图片

    一.上传的数据体格式Content-Type 1.application/x-www-form-urlencoded 2.application/json 3.multipart/form-data ...

  10. 37.Spring注解相关面试题

    1.@Resource和@Autowired 区别 2.@Repository.@Component.@Service.@Controller 区别