Я пытаюсь это:
final PoolableConnectionFactory factory = new PoolableConnectionFactory(
new DriverManagerConnectionFactory("jdbc:hsqldb:mem:testdb", "sa", ""),
new GenericObjectPool(null),
null,
"SELECT 1 from INFORMATION_SCHEMA.SYSTEM_USERS",
true,
false,
Connection.TRANSACTION_NONE
);
DataSource ds = new PoolingDataSource(factory.getPool());
ds.getConnection();
Безрезультатно, выдается исключение:
java.util.NoSuchElementException: Could not create a validated object, cause: Invalid argument in JDBC call
at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1191)
at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:106)
Что не так?