I am trying to retrieve lead records if the email or userid matches. enter image description here

Now there is no way to add a filter logic for the OR condition. Based on some comments on this idea https://success.salesforce.com/ideaView?id=0873A000000lDvCQAU the OR condition works if we use the same fields.

Does anyone have any workaround for getting the OR conditions on multiple fields to work on the flow?


You are right. OR conditions don't work for multiple field. A workaround would be to use to 2 Get Record elements. One for UserId another for Email. After each Get Record use a Loop element to iterate over fetched records and add in a Record Collection Variable. Flow would look something like this:

enter image description here enter image description here

Record Collection Variable may contain duplicates which can be handled using Loop (to iterate over Get_By_UserId) and Decision (Add to Collection Variable if not already present).

| improve this answer | |
  • Thanks. Looks like a good workaround – Prady Oct 31 '19 at 13:37
  • Welcome. Please look out for the duplicates though. – Pranav Parakh Oct 31 '19 at 13:40

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.