[SalesForce] Validation rule to prevent field update

Background

In opportunity object I've got two fields

  • Stage (Initiated, Develop, Submitted, Review, Hold, Closed)
  • Status (open, lost, rejected, withdrawn, closed)

Objective

I'm trying to create validation rule to prevent Stage being set to Closed when Status = Open.

What I've done so far

In process builder, I've got the criteria as AND(ISCHANGED(Stage) = True, Stage = Closed, Status = Open). But I do not know where to go from here.

Request

Does anyone know what actions I need to enter into process builder, to prevent the stage field from updating to Closed (or revert it back to its prior value). if Status = Open?

Best Answer

Process Builder cannot stop edits/changes directly; it can only revert changes. Instead, go to Object Manager in Setup, then click on Opportunity, then Validation Rules (If you're in Classic, Setup > Customize > Opportunity > Validation Rules). You can use the formula there.