Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
b.gonzalez

Custom Formula Field on Opportunity?

I am trying to create a Closed Won amount custom formula field.  When the Stage = Closed Won, the fiield should display the Amount value if the 'Total Amount for Current FQ' is \$.0.00 or 'Null' or the 'Total AMount for Current FQ' value. I am not sure how to write these formula. Here are the fields that would be in the formula:

StageName =  Closed Won
Total_Amount_for_Current_FQ__c
Amount

I appreciate the help!

Thanks!
sandeep@Salesforce
Hi,
Here is the formula for you
`IF( AND(ISPICKVAL( StageName , 'Closed Won'),OR(Total_Amount_for_Current_FQ__c= 0.0, ISNULL(Total_Amount_for_Current_FQ__c))) , Amount, Total_Amount_for_Current_FQ__c)`

Keep its return type is currency ( if you want)
Mark this answer is best answer so that it can help others as well.

Thanks
Sandeep Singhal
http://www.codespokes.com/

sandeep@Salesforce
Hi,
Here is the formula for you
`IF( AND(ISPICKVAL( StageName , 'Closed Won'),OR(Total_Amount_for_Current_FQ__c= 0.0, ISNULL(Total_Amount_for_Current_FQ__c))) , Amount, Total_Amount_for_Current_FQ__c)`

Keep its return type is currency ( if you want)
Mark this answer is best answer so that it can help others as well.

Thanks
Sandeep Singhal
http://www.codespokes.com/
This was selected as the best answer
sandeep@Salesforce
OR if you have a requirement that amount should only be displayed when stage is closed won other wise it should be anyothervalue then

IF(ISPICKVAL( StageName , 'Closed Won'), IF(OR(Total_Amount_for_Current_FQ__c= 0.0, ISNULL(Total_Amount_for_Current_FQ__c)), Amount, Total_Amount_for_Current_FQ__c), 'AnyotherValueORfield')
Thanks
Sandeep Singhal
http://www.codespokes.com/
b.gonzalez
Thank you!

Beth