com.github.pagehelper.PageHelper cannot be cast to org.apache.ibatis.plugin.Interceptor
Posted 司徒二条
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了com.github.pagehelper.PageHelper cannot be cast to org.apache.ibatis.plugin.Interceptor相关的知识,希望对你有一定的参考价值。
在MyBatis的配置文件中修改对pageHelper的配置
修改前
<plugins> <plugin interceptor="com.github.pagehelper.PageHelper"> <!-- 配置数据库的方言 --> <!-- 设置数据库类型 Oracle,mysql,MariaDB,SQLite,Hsqldb,PostgreSQL六种数据库--> <property name="dialect" value="mysql"/> </plugin> </plugins>
修改后
<plugins> <plugin interceptor="com.github.pagehelper.PageInterceptor"> <!-- 配置数据库的方言 --> <!-- 设置数据库类型 Oracle,Mysql,MariaDB,SQLite,Hsqldb,PostgreSQL六种数据库--> <!-- <property name="dialect" value="mysql"/> --> </plugin> </plugins>
以上是关于com.github.pagehelper.PageHelper cannot be cast to org.apache.ibatis.plugin.Interceptor的主要内容,如果未能解决你的问题,请参考以下文章