|
版本: |
BeX5V3.5 |
小版本号: |
|
|
|
数据库: |
MySQL |
服务器操作系统: |
Windows |
应用服务器: |
Tomcat |
客户端操作系统: |
Windows 其它 |
浏览器: |
IE10 |
|
|
本帖最后由 zzqqstc 于 2017-7-23 22:30 编辑
action 最后执行一下sql语句出错
update SA_Task t set t.sStatusID='tesFinished',t.sStatusName='已完成',t.sExpectStartTime="2017-07-23 21:39:12.517" where t="3baaaec36ce111e7b55700ffb0ebc54b"
/* SQL错误(1054):Unknown column 't' in 'where clause' */
我改成了 t.sID 好像也不行 java代码 以及 控制台的错误输出如下:
Java代码:
sql = "update SA_Task t set t.sStatusID='tesFinished',t.sStatusName='已完成',t.sExpectStartTime = :currentDate where t.sID="
+ taskID;
Map<String, Object> param = new HashMap<String, Object>();
param.put("currentDate", CommonUtils.getCurrentDateTime());
System.out.println("\nsql --- " + sql);
System.out.println("\nparams - " + param);
count = KSQL.executeUpdate(sql, param, sysDataModel, null);
控制台输出:
sql --- update SA_Task t set t.sStatusID='tesFinished',t.sStatusName='已完成',t.
sExpectStartTime = :currentDate where t.sID="3baaaec36ce111e7b55700ffb0ebc54b"
params - {currentDate=2017-07-23 22:19:09.407}
2017-07-23 22:19:09 excute stream action, params:{process=/OA/survey/process/sur
veyAnswer/surveyAnswerProcess, activity=surveyAnswerActivity, action=commitSurve
y, parameters={taskID="3baaaec36ce111e7b55700ffb0ebc54b"}}
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.justep.system.action.Engine.invokeActions(Native Method)
at com.justep.system.action.Engine.invokeActions(Unknown Source)
at com.justep.business.server.BusinessServer.doAction(Unknown Source)
at com.justep.business.server.BusinessServer.doExcute(Unknown Source)
at com.justep.business.server.BusinessServer.excute(Unknown Source)
at com.justep.business.server.BusinessServer.excuteGETAction(Unknown Sou
rce)
at com.justep.business.server.BusinessServer.excuteGETAction(Unknown Sou
rce)
at com.justep.business.server.BusinessServerServlet.execService(Unknown
Source)
at com.justep.business.server.BusinessServerServlet.service(Unknown Sour
ce)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
at com.justep.x.bs.BusinessServerServlet.service(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
a:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:861)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
ss(Http11Protocol.java:606)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:48
9)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.justep.exception.BusinessException: 编码: JUSTEP150210; 提示: 执
行KSQL出错, KSQL: update SA_Task t set t.sStatusID='tesFinished',t.sStatusName='
已完成',t.sExpectStartTime = :currentDate where t.sID="3baaaec36ce111e7b55700ffb
0ebc54b"
at com.justep.exception.BusinessException.create(Unknown Source)
at com.justep.system.data.impl.TableUtilsImplement.ksqlUpdate(Unknown So
urce)
at com.justep.system.data.impl.TableUtilsImplement.ksqlExecuteUpdate(Unk
nown Source)
at com.justep.system.data.KSQL.executeUpdate(Unknown Source)
at com.justep.system.data.KSQL.executeUpdate(Unknown Source)
at com.justep.system.data.KSQL.executeUpdate(Unknown Source)
at Survey.commitSurvey(Survey.java:436)
... 28 more
Caused by: com.justep.exception.KSQLException: 编码: JUSTEP154046; 提示: KSQL语
法错误, te where t.sID=^^"3baaaec36ce111中未找到需要的元素, 位置113期望是以下元
素之一:STRING, NUMBER, ONE_RELATION, IDENTIFER, VARIABLE
at com.justep.exception.KSQLException.create(Unknown Source)
at com.justep.system.ksql.parser.AbstractParser.constExpression(Unknown
Source)
at com.justep.system.ksql.parser.AbstractParser.unaryExpression(Unknown
Source)
at com.justep.system.ksql.parser.AbstractParser.multiExpression(Unknown
Source)
at com.justep.system.ksql.parser.AbstractParser.addExpression(Unknown So
urce)
at com.justep.system.ksql.parser.AbstractParser.compExpression(Unknown S
ource)
at com.justep.system.ksql.parser.AbstractParser.notExpression(Unknown So
urce)
at com.justep.system.ksql.parser.AbstractParser.andExpression(Unknown So
urce)
at com.justep.system.ksql.parser.AbstractParser.orExpression(Unknown Sou
rce)
at com.justep.system.ksql.parser.AbstractParser.conditionExpression(Unkn
own Source)
at com.justep.system.ksql.parser.AbstractParser.whereExpression(Unknown
Source)
at com.justep.system.ksql.parser.UpdateParser.start(Unknown Source)
at com.justep.system.ksql.parser.AbstractParser.parse(Unknown Source)
... 34 more
|
|