[activiti] Activiti 5.18 的Mybatis版本依赖问题
测试activiti 是查询Task时抛出一个异常:
org.apache.ibatis.exceptions.PersistenceException:
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'order by RES.ID_ asc
LIMIT 2147483647 OFFSET 0' at line 15
### The error may exist in org/activiti/db/mapping/entity/Task.xml
### The error may involve org.activiti.engine.impl.persistence.entity.TaskEntity.selectTaskByQueryCriteria-Inline
### The error occurred while setting parameters
### SQL: select distinct RES.* from ACT_RU_TASK RES WHERE RES.ASSIGNEE_ = ? order by order by RES.ID_ asc LIMIT ? OFFSET ?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'order by RES.ID_ asc
LIMIT 2147483647 OFFSET 0' at line 15
at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:122)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:113)
at org.activiti.engine.impl.db.DbSqlSession.selectListWithRawParameter(DbSqlSession.java:435)
at org.activiti.engine.impl.db.DbSqlSession.selectList(DbSqlSession.java:426)
at org.activiti.engine.impl.persistence.entity.TaskEntityManager.findTasksByQueryCriteria(TaskEntityManager.java:135)
at org.activiti.engine.impl.TaskQueryImpl.executeList(TaskQueryImpl.java:1219)
at org.activiti.engine.impl.AbstractQuery.execute(AbstractQuery.java:164)
at org.activiti.engine.impl.interceptor.CommandInvoker.execute(CommandInvoker.java:24)
at org.activiti.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:57)
at org.activiti.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:31)
at org.activiti.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:40)
at org.activiti.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:35)
at org.activiti.engine.impl.AbstractQuery.list(AbstractQuery.java:138)
at com.xwolf.activiti.service.LeaveProcess.queryMyTask(LeaveProcess.java:46)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'order by RES.ID_ asc
LIMIT 2147483647 OFFSET 0' at line 15
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
at com.mysql.jdbc.Util.getInstance(Util.java:381)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1030)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3491)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3423)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1936)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2060)
at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2542)
at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1734)
at com.mysql.jdbc.PreparedStatement.execute(PreparedStatement.java:995)
at org.apache.ibatis.executor.statement.PreparedStatementHandler.query(PreparedStatementHandler.java:62)
at org.apache.ibatis.executor.statement.RoutingStatementHandler.query(RoutingStatementHandler.java:78)
at org.apache.ibatis.executor.SimpleExecutor.doQuery(SimpleExecutor.java:62)
at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:303)
at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:154)
at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:102)
at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:82)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:120)
... 36 more
SQL语法错误,感觉是mybatis版本问题,具体mybatis源码没有仔细看过,将mybatis版本从3.3.1 换为3.2.8后测试通过。
网上看到类似的一个问题:
Activiti 5.18 的Mybatis版本问题
[activiti] Activiti 5.18 的Mybatis版本依赖问题的更多相关文章
- Spring Cloud和eureka启动报错 解决版本依赖关系
导读 An attempt was made to call a method that does not exist. The attempt was made from the following ...
- Spring IO Platform 解决Spring项目组合中版本依赖
简介: Spring IO Platform是Spring官网中排第一位的项目.它将Spring的核心API集成到一个适用于现代应用程序的平台中.提供了Spring项目组合中的版本依赖.这些依赖关系是 ...
- .Net版本依赖之坑引发的搜查
前言 今天上午,一个客户反馈XX消息没有推送到第三方链接.于是我查看了推送日志列表,并没有今天的.接着登录服务器查询文件日志,看到了记录.我们的代码步骤是消息先推送到消息队列,消费消息队列时,记录文件 ...
- myBatis各种依赖包
下载地址:myBatis各种依赖包
- Springcloud的版本依赖问题(最全,包含springCloud所有的版本)
版权声明:本文为博主原创文章,遵循CC 4.0 BY版权协议,转载请附上原文出处链接和本声明. 本文链接:https://blog.csdn.net/qq_42105629/article/detai ...
- linux版本依赖
记住, 你的模块代码一定要为每个它要连接的内核版本重新编译 -- 至少, 在缺乏 modversions 时, 这里不涉及因为它们更多的是给内核发布制作者, 而不是开发者. 模块 是紧密结合到一个特殊 ...
- ubuntu 18及以上版本配置IP的方法,你get了吗
本文讲讲 Ubuntu 18 及以上版本配置 IP 的方法,为什么它值得一讲,因为以 Ubuntu 16 为首的版本的配置方法已经不适用了,如果你还不知道,那本文正好 get 一个新技能. Ubunt ...
- Activiti系列:如何把Activiti工程转换为maven工程以解决依赖项找不到的问题
在eclipse中安装了Activiti插件之后,就可以新建Activiti工程,但是在实际使用时发现,在该工程中间新建Activiti Diagram,绘制好该图形之后,右键,新建单元测试,选择ju ...
- gradle入门(1-8)gradle 的依赖查看、依赖排除和指定版本(需要验证!)
一.依赖查看 gradle dependencies 在gradle dependencies输出会有如下几种标记: 1.版本 : 唯一的依赖. 2.版本():还存在该库其他版本的依赖或者间接依赖,并 ...
随机推荐
- 中级iOS开发面试题
1:MVC的理解 MVC设计模式考虑三种对象:数据模型对象,视图对象和控制器对象. 数据模型:负责存储.定义.操作数据: 视图:展示数据给用户,和用户进行操作交互: 控制器:M与V的协调者,控制获取数 ...
- SqlSever2005 一千万条以上记录分页数据库优化经验总结
http://www.cnblogs.com/jirigala/archive/2010/11/03/1868011.html 待测试???
- 《JS高程》基本类型和引用类型的值学习笔记
ECMAScript 变量可能包含两种不同数据类型的值:基本类型值和引用类型值. 创建方式类似:创建一个变量并为其赋值. (1)基本类型值和引用类型值比较 基本类型值 引用类型值 简单的数据段 可能由 ...
- Canvas 获取颜色值
Canvas 是 HTML5 的画布元素,按照像素绘制图像.有时需要用户点击鼠标的时候获取像素值. 获取画布元素 var canvas = document.getElementById(" ...
- Log4J 使用实战
前言: 日志在开发和服务中扮演重要的角色, 有人用来追查/分析问题, 有人通过日志, 来记录重要的信息. 日志是数据分析和统计最重要的数据来源. 在Java领域, Log4j日志框架成为java开发人 ...
- union与union的区别
把2个具有相同列及数据类型的 结果 放到一起显示,并且不去重.select a,b,c from table1union allselect ca,cb,cc from table2 而union会对 ...
- 使用Spring Aop验证方法参数是否合法
先定义两个注解类ValidateGroup 和 ValidateFiled ValidateGroup .java package com.zf.ann; import java.lang.annot ...
- ArrayList线程不安全
ArrayList线程不安全分析 http://wsmajunfeng.iteye.com/blog/1493941 一个 ArrayList ,在添加一个元素的时候,它可能会有两步来完成:1. ...
- POJ Girls and Boys (最大独立点集)
Girls and Boys Time Limit: 5000MS Memo ...
- 利用mybatis_generator自动生成Dao、Model、Mapping相关文件
技术交流群:233513714 http://blog.csdn.net/wyc_cs/article/details/9023117 http://www.cnblogs.com/smileberr ...