commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pramodh Peddi" <>
Subject [dbcp] java.sql.SQLException: Incorrect arguments to mysql_stmt_execute
Date Wed, 10 Aug 2005 18:46:42 GMT

I am using commons-dbcp-1.2 to manage my db connection pool w/
MySQL-4.1.4-gamma. On Linux (Suse) I am finding an SQLException very
frequently so far. The actual exception is "java.sql.SQLException:
Incorrect arguments to mysql_stmt_execute". Not all the queries are
giving this problem. Only a couple of them, which are very simple, are
being problematic. This happened ever since I am using the commons-dbcp
infrastructure to manage the db connection pool. So far I observed that
the problematic queries look like "SELECT COLUMN1, COLUMN2, COLUMN3,
COLUMN4 FROM MYTABLE". (Note: one of the queries uses DISTINCT) This is
the dbcp-related configuration I have (I guess most significant thing is
poolPreparedStatements = true):



factory = org.apache.commons.dbcp.BasicDataSourceFactory

username = myuser

password = mypwd

driverClassName = com.mysql.jdbc.Driver

url =

maxActive = 15

maxWait = 360000

removeAbandonedTimeout = 1800000

removeAbandoned = true

logAbandoned = true

poolPreparedStatements = true



Any Ideas?



  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message