1

Hi I am using Civicrm api v3. I am trying NOT Like condition with single condition it is working. But i need to apply two conditions with string1 and string2.

    $contribution = civicrm_api3('Contribution', 'get', [
        'sequential' => 1,
        // 'financial_type_id' => "Donation",
        'receive_date' => ['BETWEEN' => ["01-01-2021 00:00:00", "31-12-2021 23:59:59"]],
        'contact_id' => $contact_id,
        'contribution_status_id' => "Completed",
        'source' => ['NOT LIKE' => "%string1%"],
       'source' => ['NOT LIKE' => "%string2%"],
        'options' => ['limit' => 5000, 'sort' => "receive_date ASC"],
    ]);
2

You can do multiple not like statements using api4

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.