model.setLimit(limit); model.setOffset(offset); model.getEvents(); offset += limit; // Stop when we get nothing keepgoing = (model.rowCount() > 0);