function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
rbohacrbohac 

Workflow comparing 2 fields

  I would like to create a rule based on two fields rather than comparing a field to a fixed example.

 

Specifically I would like to compare the  Opportunity Product: List Price against the Opportunity Product: Sales Price and update a field only if Sales Price < List Price.

 

Is there a way to accomplish this? I can't seem to figure out how to compare one field against another in the workflow rules

Best Answer chosen by Admin (Salesforce Developers) 
MarkSilberMarkSilber

You would need to change the workflow rule criteria from "criteria are met" to "formula evaluates to true" and then manually build your criteria. You could also do the same thing in the field update part of the workflow rule, but that is a little more complicated than having the criteria as part of the main workflow and only works for text, currency and number fields.

 

 

UnitPrice < ListPrice