Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.3
-
None
-
None
-
windows xp,tomcat,mssql,mysql,sqlite
Description
i have a table maintances(id,tr_userid,trouble,tr_time),id is autoincrement.when i use code below insert into table
QueryRunner runner = new QueryRunner();
runner.update(conn,"INSERT INTO maintances(tr_userid,trouble,tr_time) values(?,?,?)",1,"2","2009-01-01");
successed in mysql,sqlite
in mssql has error(Keyword 'where' syntax error near);i test in mssql2000,mssql2005,use new and old jdbc, the same result.
stacktrace
Caused by:java.sql.SQLException:com.microsoft.sqlserver.jdbc.SQLServerException:关键字'where'附近有语法错误。Query:,"INSERT INTO maintances(tr_userid,trouble,tr_time) values(?,?,?) Parameters:[1,2,2009-01-01]
at org.apache.commons.dbutils.QueryRunner.rethrow(QueryRunner.java:542)
at org.apache.commons.dbutils.QueryRunner.rethrow(QueryRunner.java:599)
at com.softwarementors.extjs.djn.demo.Maintance.insertMaintance(Maintance.java:49)