diff --git a/api/v3/Lid/Indelen.php b/api/v3/Lid/Indelen.php index 75f6ef8..9bc17b6 100644 --- a/api/v3/Lid/Indelen.php +++ b/api/v3/Lid/Indelen.php @@ -45,7 +45,7 @@ function civicrm_api3_lid_Indelen($params) { } $nogInTeDelenGroepId = CRM_Core_DAO::singleValueQuery("SELECT id FROM civicrm_group WHERE name = %1", [1 => ["bij1_nog_in_te_delen", "String"]]); $returnValues = []; - $lid = CRM_Core_DAO::executeQuery("SELECT DISTINCT(contact_id) FROM civicrm_contribution WHERE contact_id >= %1 ORDER BY contact_id", [1 => [$min, "Integer"]]); + $lid = CRM_Core_DAO::executeQuery("SELECT DISTINCT(contact_id) FROM civicrm_contribution WHERE contact_id >= %1 ORDER BY contact_id LIMIT 1000", [1 => [$min, "Integer"]]); while ($lid->fetch()) { $inschrijvingsDatum = $contact->haalInschrijvingsDatum((int) $lid->contact_id); if ($contact->heeftBasisBetaald((int) $lid->contact_id, $vanDatum, $totDatum)) {