• java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for com.bjsxt.mapper.PeopleMapper


    报错信息:


    Type Exception Report

    Description The server encountered an unexpected condition that prevented it from fulfilling the request.

    Exception

    org.apache.ibatis.exceptions.PersistenceException: 
    ### Error querying database.  Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for com.bjsxt.mapper.PeopleMapper
    ### Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for com.bjsxt.mapper.PeopleMapper
    	org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:26)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:111)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:102)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:98)
    	com.bjsxt.service.impl.PeopleServiceImpl.show(PeopleServiceImpl.java:21)
    	com.bjsxt.servlet.ShowServlet.service(ShowServlet.java:26)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
    	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    	org.apache.logging.log4j.core.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:66)
    

    Root Cause

    java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for com.bjsxt.mapper.PeopleMapper
    	org.apache.ibatis.session.Configuration$StrictMap.get(Configuration.java:797)
    	org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:631)
    	org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:624)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:107)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:102)
    	org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:98)
    	com.bjsxt.service.impl.PeopleServiceImpl.show(PeopleServiceImpl.java:21)
    	com.bjsxt.servlet.ShowServlet.service(ShowServlet.java:26)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
    	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    	org.apache.logging.log4j.core.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:66)

    错误的原因 : 在service层调用mapper的时候 只写了命名空间namespace 没有指定下面的方法selAll

    
    
  • 相关阅读:
    汉堡博客
    复利计算——结对1.0
    《构建之法》第4章读后感
    Compound Interest Calculator4.0
    实验一 命令解释程序的编写
    Compound Interest Calculator3.0续
    1203正规式转换为有穷自动机
    优缺点评价
    语文文法
    词法分析实验总结
  • 原文地址:https://www.cnblogs.com/spicy/p/10199073.html
Copyright © 2020-2023  润新知