I am using SQLiteJDBC as a shell for the embedded database for my small Java application. Every time I execute an INSERT statement, I get the following exception:
request does not return ResultSet
I am wondering if the JDBC Method Statement.executeStatement (String) is trying to return a ResultSet, but the SQLite driver knows that the INSERT statements do not return anything; perhaps SQLiteJDBC throws an error because it should not return the ResultSet requested by the query?!?
Here is the code that throws the exception - I will definitely install and close all resources properly:
statement = con.createStatement(); String sql = "INSERT INTO widgets (widget_age) VALUES (27)"; statement.executeStatement(sql);
Any ideas?!?
source share