1

I can't find it in the docs, but there has to be a maximum. In a salesforce flow, what is the maximum number of records a fast lookup can return. What happens if the number is higher than the max?

1
3

I just tested this, and there's no limit for the number of rows a Fast Lookup can return directly, but you are bound by the governor limits in Apex Code and Visualforce: heap size, query row limits, query limits, view state size, and CPU time. Attempting to update those records may also run into other limits, such as the DML statement limit and the DML total record limit (plus any of the previously mentioned limits).

3
  • Thanks and it turns out that looping through them the most likely limit that will be hit is: Maximum number of executed elements at run time 2,000 so it's very likely less than 2000 rows that can be handled and dependent on the complexity of the flow. The more complex, the lower the number of rows that can be handled, rendering it only useful for very simple cases, anything else is better off as a trigger. – Scott Morrison May 19 '16 at 20:16
  • @ScottMorrison Mostly true. However, every "screen" is a separate transaction, which is how you could still process more than 2k records (I've actually built something like this), but then you still risk the other limits, depending on how it's laid out. – sfdcfox May 19 '16 at 20:50
  • If it's an auto-executing flow triggered from process builder there aren't any screens so in that case everything appears to be in the same transaction – Scott Morrison May 25 '16 at 19:32
1

It's a bit late to be chiming in on this, however, I'll comment in case anyone finds this thread in the future.

If you are in an auto-executing flow, you can put in a wait element and that will reset the transaction counter the same as a screen will.

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.