sqlNextPK.executeQuery();
dbConnection.executeQuery(sqlNextPK);
    private int getNextPK(String entity, String pk) {        if ((pk == null) || (entity == null))             throw new IllegalArgumentException();                java.sql.PreparedStatement sqlNextPK =             dbConnection.prepareStatement("SELECT MAX(?) FROM ?;");                try {            sqlNextPK.setString(1, pk);            sqlNextPK.setString(2, entity);                        ResultSet result =                  sqlNextPK.executeQuery();            result.next();            return (result.getInt(1) + 1);        } catch (SQLException e) {            DataBus.logger.fatal("Error while getting next primary key.");            e.printStackTrace();            throw new RuntimeException("Erroneous database query.");        }    }