I have a picklist field, Values: value1, value2, value3, I am trying to count the number of days that value1 stayed, until it changed to value2 and going forward.

I am trying to do with workflow as

criteria: picklist=value1 field update(Days in value1): today() - value1 update date.

where can I get this "value1 update date" Date in order to get the number of days?

I might be wrong with the approach, feel free to give me your suggestions.


1 Answer 1


I think you are trying to do a histogram for picklist values.

I have done something similar with Status field on the Case Object. We use the case history object and we have history tracking enabled on the status field.

We query the case history object for the record to create the status change by time. We are use the same dataset to create multiple visualization from when the picklist field changed from the history table.

I hope this helps you.

  • Hi Mohit, Thanks for taking the time and giving me an answer, I am new in salesforce and I am trying to solve it by workflow and formula I have very little knowledge with coding, here is the part of the task that best describes my question. @Mohit Gupta
    – Siva
    Jan 23, 2020 at 5:52
  • I need to add the following fields for reporting purposes to Tradeline object. Days in Tier 1 - the count of days that a tradeline has a Legal Status of "Tier 1" Days in Tier 2 - the count of days that a tradeline has a Legal Status of "Tier 2" Days in Tier 3 - the count of days that a tradeline has a Legal Status of "Tier 3" These fields should start counting when the legal status is placed into the respective value, and should stop counting when moved out of that status. Tradeline = Object. Legal Status = Picklist.
    – Siva
    Jan 23, 2020 at 5:54
  • @Siva - Let me think through. Will get back to you in a day with a possible solution using process builder. Jan 23, 2020 at 22:20
  • @Siva - sorry fro the late response. I did not have time to build out a process builder. But please look through these 2 articles. success.salesforce.com/answers?id=9063A000000pK4JQAU salesforce.stackexchange.com/questions/76619/… These are solving the same process but with different picklist types values. Jan 31, 2020 at 4:24
  • Thanks 😊 for your time and efforts. First link is almost similar to my answer. And that solved my question.
    – Siva
    Feb 1, 2020 at 14:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .