Suppose we have a field on Account as Active of type picklist and has 2 values: Yes, No. While creating the value we can provide any value amongst this picklist but once we update it to Yes, It can’t be moved to No. How can we implement this scenario?
SituationalSenior Salesforce DeveloperSalesforce DeveloperTo implement this scenario, I would use a combination of validation rules and workflow rules. First, I would create a validation rule that checks if the picklist value is being changed from 'Yes' to 'No'. If it is, the rule would prevent the update and display an error message. This ensures that once an account is marked as active, it cannot revert back.
Next, I would set up a workflow rule to trigger an alert or task for the user attempting to make this change, providing clarity on why the action is not permitted. The trade-off here is that while this approach enforces data integrity, it may frustrate users who are unaware of the restriction. Success would be measured by the reduction in erroneous updates and user feedback on the clarity of the error messages.