Formula fields in Salesforce : Formulas are those which are used to calculate something, combine data from multiple fields, to check for a condition, to show information from one record on a related record.These formulas will be simple or complex with layers of nested logic s. Formula fields is based on other fields values and it is shown only in detailed view of an object and can not be viewed in editable view of an object.
Where we use formulas fields in Salesforce ?
- Business logic.
- formula field.
- Default values for fields.
- Workflow rules .
- Validation rules
- Reporting.
- Buttons and Links.
Formulas in salesforce can be made up of two Parts .
- Formula Syntax : Which we write n the formula editor.
- Database query .
Formula syntax allows 3,900 maximum number of characters and the size of the formula when saved will be 4,000 bytes.Depending up on the Formula syntax and query the complexity increases.
Follow below limitation when using formulas to reduce complexity.
- Minimize the number of references to other fields.
- Minimize the number of times formula functions are called.
- Rethink about your picklist.
- Choose another way about the problem
- If all above cases fails use Workflow field update.
Operators and Functions used for formulas.