Newer Version Available
Sample Financial Calculations Formulas
| Available in: both Salesforce Classic and Lightning Experience |
| Available in: All Editions |
For details about using the functions included in these samples, see Formula Operators and Functions.
Compound Interest
This formula calculates the interest, you will have after T years, compounded M times per year.
Compound Interest Continuous
This formula calculates the interest that will have accumulated after T years, if continuously compounded.
Consultant Cost
This formula calculates the number of consulting days times 1200 given that this formula field is a currency data type and consulting charges a rate of $1200 per day. Note that Consulting Days is a custom field.
Gross Margin
This formula provides a simple calculation of gross margin. In this formula example, Total Sales and Cost of Goods Sold are custom currency fields.
Payment Due Indicator
This formula returns the date five days after the contract start date whenever Payment Due Date is blank. Payment Due Date is a custom date field.
Payment Status
This formula determines if the payment due date is past and the payment status is “UNPAID.” If so, it returns the text “PAYMENT OVERDUE” and if not, it leaves the field blank. This example uses a custom date field called Payment Due Date and a text custom field called Payment Status on contracts.