-79750

Method only for queries

The Statement.executeQuery(String) and PreparedStatement.executeQuery() methods should only be used if the statement is a SELECT statement. For other statements, use the Statement.execute(String), Statement.executeBatch(), Statement.executeUpdate(String), Statement.getUpdateCount(), Statement.getResultSet(), or PreparedStatement.executeUpdate() method.