Skip to main content
I am trying to create a formula field to calculate the time in days of how long it takes to close a product.  We have a custom status field that is much like the opporutnity stage field. I want to know how long it takes from the day the product is added to the day it is moved to won.

 

CreatedDate -   DATEVALUE( ISPICKVAL( Opportunity_Product_Status__c, Won))  

 

I keep getting this "Error: Field Won does not exist. Check spelling."

 

Can anyone make any recomendations on how to do this?
4 个回答
  1. 2016年8月12日 18:16

    Danielle, the following syntax is incorrect:

    CreatedDate - DATEVALUE( ISPICKVAL( Opportunity_Product_Status__c, Won))

     

    1. CreatedDate is actually a datetime field so you need to wrap it inside a DATEVALUE function.

     

    2. You must create a custom date field  (Won Date) on Opportunity Product object to capture the date when the Opportunity Product Status is set to 'Won'. This would be done via a workflow rule and field update. DATEVALUE cannot be wrapped around an ISPICKVAL statement to extract the date value out of it. 

     

    3. After doing the above, the formula would be:

    Won_Date__c - DATEVALUE(CreatedDate)

    And that's it.

     

     
0/9000