SSM整合遇到问题

123 阅读1分钟

ssm整合中:

java.lang.ClassNotFoundException: org.apache.ibatis.session.SqlSessionFactory

ssm整合中pom文件中的mybatis的相关包没有导入全

<dependency>
            <groupId>org.mybatis</groupId>
            <artifactId>mybatis-spring</artifactId>
            <version>2.0.6</version>
 </dependency><dependency>
            <groupId>org.mybatis</groupId>
            <artifactId>mybatis</artifactId>
            <version>3.5.7</version>
</dependency>

java.lang.ClassNotFoundException: Cannot find class: com.github.pagehelper.pageInterceper

ssm整合中 在mybati-config.xml配置文件中配置pagehelper的plugins标签中的interceptor标签写错


--interceptor中的全类名要注意单词拼写和大小写
<plugins>
    <plugin interceptor="com.github.pagehelper.pageIntercepor"></plugin>
</plugins>

Failed to complete request: org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.zhangke.ssm.mapper.EmployeeMapper.getAllEmployee

放置mapper配置文件的包写错了:文件目录之间用了 . 分隔,没有用/分隔导致找不到文件