Questions tagged [formula]

A formula is an algorithm that derives its value from other fields, expressions, or values. Formulas can help you automatically calculate the value of a field based on other fields (from Salesforce doc). Formulas can be used in many areas of Salesforce other than just Formula Fields, such as Validation Rules and criteria for Workflow Rules and Approval Processes.

Filter by
Sorted by
Tagged with
0 votes
1 answer
16 views

Parsing out information from a description field

I am trying to parse out a company name from an email domain. Right now we are using email to case. We are using that process to trigger a flow to create a record on another object. The email is ...
user avatar
  • 1
0 votes
0 answers
17 views

Process Builder Decision not going through even the Criteria is fulfilling

I have a Process Builder (We change to Flow soon- but want to have all the automation to the record at one place so that it is easy to move to Flow). Use Case: When the Expected Revenue Date is moved ...
user avatar
-1 votes
1 answer
21 views

The formula expression is invalid: Incorrect number of parameters for function 'IF()'. Expected 3, received 2

Receiving an error when trying to save the below formula. The requirement is that if the first variable is empty, to retrieve the value for the second variable. IF({!var_EmailAddress_1} = "",...
user avatar
0 votes
1 answer
31 views

Formula field that returns specified valued based on related field

I'm trying to create a formula field on opportunity that returns the value 'engaged' if the opportunity owner = SDR or AE and the opportunity CreatedDate was less than 4 months ago, but if the ...
user avatar
-2 votes
0 answers
18 views

formula in salesforce force [closed]

If Stage = 3. Solution or 4. Negotiate AND Record Type ID = 012D00000003KX9IAM AND Created After = 01/01/2022 Then to save Proposal_ITT_Submission_Date__c = !NULL
user avatar
  • 1
0 votes
1 answer
34 views

Way to generate contract numbers while creation according to a particular format

Is there a way to generate a contract number while creating a contract such that If the Contract created on "july 3rd 2022" then Starting number will be 2300010 If the Contract created on &...
user avatar
0 votes
1 answer
24 views

Rolling up Primary Contact Picklist Value to text on Account

I'm attempting to solve what I think is a fairly simple problem. We are using NPSP, and track our board members on the Contact level. For some complex reporting reasons, I need a way to simply display ...
user avatar
0 votes
1 answer
20 views

Formula within a flow - loads of 2 part IF statements - must be a better way of doing this

I'm new here but the questions and answers here have helped me before so thought I'd try posting. I'm trying to use a boolean formula that will be referenced in a flow. The idea is to update a ...
user avatar
  • 1
0 votes
3 answers
20 views

The formula expression is invalid: Field Existing_Contact_Loop is a picklist field. Picklist fields are only supported in certain functions

I am updating an assignment node by adding a formula for the Premise County field but since the field is a Picklist, I am getting the below error: IF( not(isblank({!Existing_Contact_Loop....
user avatar
  • 1
0 votes
1 answer
36 views

Use Salesforce Flow to check for a certain phone number format

As the title states I'm trying to check if my phone numbers are suitable to be converted to standard format (US only). Specifically, I want all 10 digit phone numbers that do not start with 1 and all ...
user avatar
-1 votes
0 answers
69 views

Auto calculate field value based on another object' field [closed]

The scenerio is, i have two objects Bus and Ticket.The "Bus" object should contain Name, Date and Time, Price per ticket, Total Seats and Reserved Seats (auto calculated based on Tickets). ...
user avatar
-1 votes
1 answer
20 views

Formula result is data type (Text), incompatible with expected data type (Number)

Trying to create a new summary formula in a report that essentially looks at an op and if it is under 25K it is "under 25K" if it is over 100K then "over 100K" and everything else ...
user avatar
  • 1
-1 votes
1 answer
40 views

To separate string containing semi colon using BR()

I have a field which has string concatenated via ; for example- If my string is A; B; C then i want to convert it into: A B C using BR() in formula field. Is it possible to do this via formula field?
user avatar
-1 votes
1 answer
17 views

IF OR NOT ISBLANK Formula nesting help [closed]

I have a formula to calculate renewal upsell only if the Previous Renewal lookup isn't blank. I want it to also only run if Type (picklist) = Renewals. IF(OR(NOT(ISBLANK(Previous_Renewal__r.Name)), ...
user avatar
  • 1
0 votes
0 answers
13 views

Using Date fields in process builder as conditions

I am trying to use date fields as part of my condition in a process builder to say: If field #1 (number) has value > 0 AND field #2 (date) is less than 30 days ago (ie. date is within the last 30 ...
user avatar
  • 1
-1 votes
1 answer
34 views

How to create following text using formula field?

I want to create a text like /lightning/n/Some_Page?c__recordId={!"+ objectfield1value +".Id}&c__docId="+ objectfield2value Whenever I am creating this it's automatically removing &...
user avatar
-1 votes
2 answers
24 views

Need a validation rule for two different account types

I have two account types, Provider and Partner. My task is to forbid to create or change the record without entering a special code in a custom field. For Partner it should start from PRT, for ...
user avatar
-1 votes
1 answer
30 views

IF Formula help - Multiple Parameters Issue

Im new to salesforce formulas and need to implement this new field (New_License_Manager_ID__c) into the formula. I received an Error: Incorrect number of parameters for function 'IF()'. Expected 3, ...
user avatar
0 votes
1 answer
23 views

Did something happen with the Month function?

I am trying to create a Row Level Report formula to give me the Opportunity Created Month. Below is a picture of the formula I am using. This has always worked before. Do you all know if something ...
user avatar
0 votes
1 answer
110 views

Update a Date field on the record in Flow Builder from the output of a formula date field

I am new to creating formulas in flows, and just starting to learn flows altogether. I am trying to create a record-triggered flow to update an existing Date field on a record based off the output of ...
user avatar
  • 3
-1 votes
1 answer
28 views

Help creating a filter [closed]

I want to create a filter that will give me the difference between Close date and Open date. I have no clue where to start.
user avatar
0 votes
0 answers
21 views

Formula to calculate latest date from different orders in a report

Hey guys :) so I'm stuck here... I got a report in salesforce containing an 'Issue Date' field, and it would help me a lot if I had the latest date from different orders... I tried to create a field ...
user avatar
-1 votes
1 answer
30 views

How to convert date/time field to a text field using formula

I have 3 fields on UI Name field1, date time field2, text field3 field3 is a formula field which is concatenation of field1 and field2. field1 + text(field2) if field1 value is Sam D field2 value is ...
user avatar
  • 3
-1 votes
1 answer
27 views

When I would change a formula, then when the value from that formula will change?

I have a hyptothetical formula (in pseudocode): if (XXX_field is empty): return 100 And I will change it to return 200 When should I see changes in that field? (200 instead of 100) Only after ...
user avatar
0 votes
2 answers
37 views

Calculating the start of a new month in SF

So essentially what I'm looking for is to be able to calculate the start of a new month. So for context, there is a checkbox that I want to clear at the start of every new month (if it's ticked ofc). ...
user avatar
-1 votes
1 answer
54 views

Summary Level Formula - Sum Closed/Won Opportunities

I am using Lightning and trying to build a summary level formula field to show the sum of closed/won opps next to the sum of total opportunities for a given time period (fiscal quarter for example). ...
user avatar
0 votes
1 answer
30 views

Tracking number of contact attempts based on Tasks under Contact

I need to update a custom field called Contact Attempts on the Contact sobject with a numerical value equal to the number of all Tasks associated with the Contact. Any time a Task is added or deleted, ...
user avatar
  • 5
0 votes
2 answers
45 views

Formula field date subtraction

I have a formula field as a boolean which should return true if the date of today and enddate has less than 3 months in between and the enddate field is not empty. I dont get the correct results. ...
user avatar
  • 2,092
-1 votes
2 answers
50 views

How to change boolean result to a compatible currency value in a formula field

I got this formula and I got stuck trying to make it work. How do I get the result to be compatible with a currency field? Any help would be greatly appreciated! The error: Formula result is data type ...
user avatar
  • 11
0 votes
1 answer
278 views

Format a date in a Flow?

I used in my flow a custom field of type date which returns to me in the email action a value of the date in the form of month Daye , Yers , what I want is to have the value of the date in the form DD/...
user avatar
0 votes
2 answers
30 views

Formula Help - alternative of using nested if in formula due to size limitation

Can anyone kindly help me with with following salesforce formula I have been trying to write. Formula is getting fairly complex and large due to number of conditions. Basically there are 4 status ...
user avatar
0 votes
0 answers
44 views

Formula Help - Fairly complex Advanced Formulas

I am a newbie to creating formula fields and have been tasked with creating about 10 different ones by end of week. I was wondering if anyone could help me or guide me to some good resources, so I can ...
user avatar
0 votes
1 answer
26 views

Return the start of a email domain

I'm looking for a formula to help return the below from an email domain. Email domain: xyzcompany.co.uk Return: "xyzcompany" Formula I have gives me the mid and returns "co." MID(...
user avatar
0 votes
0 answers
17 views

Field changed triggers approval process

I have a requirement where the Amount field when changed and falls within a range should trigger an approval process. The ranges are (10,000 to 40,000) and(40,000 to 80,000). If the record is already ...
user avatar
  • 1
0 votes
0 answers
16 views

Calculate Due Date

I'm calculating the Due Date for a custom record when a record is created. I've got a flow that does the updates but I keep getting an error when I create the formula Error: Syntax error. Missing '=' ...
user avatar
  • 1
0 votes
0 answers
27 views

Reporting Interval Between Two Dates Within Same Column

Thanks for any and all help! This is pretty straight forward but I am failing to execute. It is simple to calculate the difference between two dates if they exist in two columns, however, in this ...
user avatar
0 votes
1 answer
18 views

condition form not Leap Year issues

I want to express this condition with my formula taking into consideration the date of 02/29 End date >= Current date + 365 then green End date between Today's date + 1 and Today's date + 364 then ...
user avatar
0 votes
1 answer
103 views

Account formula field to get the latest opportunity / quote contact name?

An odd request, I know. What I'm looking for is a formula on the Account object that grabs the most recent Contact name that is assigned to an opportunity / quote. Is this possible with a formula or ...
user avatar
  • 211
-3 votes
2 answers
57 views

Weighted Probability

I want to create a formula for Weighted probability for Annual Recurring Revenue (ARR) within salesforce. Unweighted I can simply do: Opportunity.Incremental_ARR__c * PROBABILITY I believe I need an ...
user avatar
0 votes
0 answers
36 views

custom component popup via hyperlink using formula field on standard detail page

We have a hyperlink formula field on Case record page. Upon clicking of this, user is navigated to a page where we have embedded a canvas app. Business requires to have a Warning message when user is ...
user avatar
  • 2,551
0 votes
2 answers
212 views

How do I remove all text and characters from a Text field except 0 - 9

I have a Custom Mobile Phone field where we only want to see numeric characters Is there a way to remove all text except 0 through 9? I have a Substitute formula that removes (, ), -, _ etc but we ...
user avatar
0 votes
1 answer
69 views

How to resolve extra margin added in formula field with multiple images?

Here's a sample formula field called Icons IMAGE("/img/samples/color_red.gif", "Red",20,20) + ' ' + IMAGE("/img/samples/color_yellow.gif", "yellow",20,20) + ' ' ...
user avatar
  • 3,310
0 votes
0 answers
37 views

Check Queue Name in Formula

Is it possible to reference a queue by name within a case escalation formula? Salesforce throws an error that looks like the view source of an entire web page when I try to use either of these to ...
user avatar
  • 11
-1 votes
2 answers
29 views

Can I change the interval at which formula is recalculated for longer? (like for every 6 months)

I want to change a recalculation period of formula to 6 months. How could I do this? Can I do this at all? Could we schedule it somehow? With the use of flow/ code?
user avatar
0 votes
1 answer
51 views

formula field condition

I want to express this condition with my new formula type field that returns text Green Flag: is still valid Orange Flag: 1 year approaching its end. Red Flag: no longer valid so exceeds the "...
user avatar
-2 votes
1 answer
347 views

Formula: How to convert 24 hour time format to 12 hour time format [closed]

I have a date/time field Due_Date__c which I am using as a default value in an email quick action body. The return type of this formula is Text. Here is the Due_Date__c field output: 2022-03-24 16:00:...
user avatar
-1 votes
1 answer
132 views

How to show number field with its format in Text formula field

I have a field called "Annual Amount" and it is a number field. I am using this in an email quick action and I am returning this field in the email body where the return type is text. For ...
user avatar
-1 votes
1 answer
192 views

How do I remove the last instance of a character combination using formulas?

I am currently creating a flow where a text collection is combined into a single text variable using a loop. After each item of the collection is added to the text variable I add a divider such as , ...
user avatar
-3 votes
1 answer
56 views

Incorrect parameter type for operator '<'. Expected DateTime, received Date

I am trying to keep an alert in the form by creating a formula field, and I am getting the following error: Error: Incorrect parameter type for operator '<'. Expected DateTime, received Date IF( ...
user avatar
0 votes
1 answer
40 views

I have a Cross object checkbox formula that checks whether a texbox has been checked or not. Why does it return a "No" if the box is checked?

IF(Member__r.Member__r.Confirmed_Certification_Holder__c = TRUE, "Yes", "No")
user avatar

1
2 3 4 5
32