0

i'm implementing a scheduled flow to clean up old/obsolete lead records based on a a filter criteria. On Test and Dev Sandbox everything works as expected. On Prod, the flow returns an unexpected error:

enter image description here

The query looks like this: enter image description here

As soon as I remove the filter for the Lead Status, the query returns results. But the problem doesn't seem to be the selected status - I've tested also with other Lead Status and receive the same error.

Does anyone have an Idea what we do wrong? It's strange because on the Sandboxes it's working as expected.

3
  • 1) A Flow usually runs in User context unless you specify it (since Spring '20) to run in a System context (and there is a System context with Sharing). What context is this Flow running in? And are you certain the user it is run as has visibility to the Lead Status field? 2) Are you certain that in Production the Record Type you are filtering on includes "Pending" as a valid value in its associated Lead Process?
    – Moonpie
    Mar 8, 2021 at 13:24
  • 3) Or that the Lead Process is active?
    – Moonpie
    Mar 8, 2021 at 13:52
  • The scheduled flow runs as automated process with systems privileges, so it shouldn't be a permission issue. When I do the query manually with the inspector I get the expected number of leads returned so I suppose that this is also not the issue.
    – Chris.Walz
    Mar 8, 2021 at 20:50

0

You must log in to answer this question.

Browse other questions tagged .