February 28, 2023
By: Andre Porter, Associate Salesforce Administrator
Importance of Process
Whether you’re preparing a meal, building a house, or performing your morning routine – it is difficult to complete any process if there is not a clear path to follow from start to finish. The process of attempting to convert an individual or a business into a customer of your product is no different. Salesforce (or any worthwhile CRM) understands the importance of defining repeatable steps that can be followed to close a sale.
Using Salesforce as our model, we find this sales process represented by the Opportunity object in the standard Stage field. This functionality is so fundamental to the value a CRM provides that it is one of the first things that gets defined in a new organization. One of the most important automation that we build immediately following the standardization of opportunity stages is the date stamping of each stage.
What is Date Stamping?
Date stamping simply means capturing the date that an action is executed within a specific field. In our case, we are capturing the date that the opportunity enters each stage – the date that the stage value is updated to the next step in the process. We are providing a technical guide for how this automation can be constructed, but before we get there, let’s review some of the many ways that this data can be leveraged to provide insight into your business.
Some of the explanations below may be obvious. Beyond the apparent use cases for this information, one additional point of emphasis is the importance of instituting this date stamping as early as possible.
You don’t want to find yourself in a position where you are attempting to leverage the insights to improve your outcomes and the data is not available. It will take some time to generate enough records to draw meaningful conclusions. Therefore, it is always better to start collecting the information long before it will actually be used, rather than waiting.
Finding the Value
Here are some ways that these date stamps can be applied for enlightening analytics:
Funnel Velocity – It is one thing to know how long it takes to move from creation to Closed Won, but by understanding the time from stage to stage you can see deeper into the process. Knowing the average time required to accomplish each step toward success can provide a baseline of what to aim for.
Funnel Management – One approach to management is to focus on the exceptions within a process. What that means in this context is that a sales manager can spend their time reviewing Opportunities that are not progressing at the expected rate in each stage. Having that baseline stage duration makes this possible.
Prioritize Improvements – The date stamp can be used as a binary marker of how far down the funnel an opportunity progressed before falling out. Looking at where things are failing allows the sales and marketing teams to direct their efforts to improve the areas of highest need.
Automations – Not all the benefits are directly related to reporting or extracting trends at scale. Having dates captured when each stage is reached on the opportunity provides the ability to trigger actions related to those dates, or to use that information as criteria for records that should be impacted.
Flow readability - It may seem pointless now, but imagine a situation where you are trying to investigate a flow to understand what it's for or why it's giving you an error. In these situations, someone who has set up their flow with clear naming conventions, as well as documentation, makes the discovery process seamless.
Readability of flow means less time spent figuring out what the flow does!
Well commented Flow
Good Naming Conventions
Use nouns for Resources - Resources represent “things” (variables, formulas, etc) that hold data for you to access. It makes the most sense to name “things” with nouns.
Use verbs for Elements - Elements represent actions the Flow takes. Give them active names that use verbs to describe what you’re doing "Get Lead" or “Get Account”
Name the Decision with a question - Name Decisions as a question “Which Stage?” and make the outcome for the Decisions the answer “Stage 1”
Our finished flow will look like this:
First, we want to create all our stamps that will be populated in our flow. For this example, we'll be using generic Stages 0 - 5
Here is an example of what normal Time Stamps (TS) would look like
To start, we want our flow to trigger every time your related object is updated or created. In this case, we are making stage timestamps for Opportunities.
Our next step is to create a decision element to see if our record has been created or updated.
In this Decision element we're going to ask first: Has a new Opportunity been created? I've done this by asking if $PriorRecord > Created Date is Null. You can also do this via a Variable - formula - Text evaluation to true. ISNEW()
If this decision evaluates to ttFrom here our next step will be to create an assignment to set the initial Stage Timestamp Date.
This will be our bread and butter, and the main mission of this flow, Stamping the time! In this case, our initial stage Time Stamp will be Stage 0 and we will make this equal to the current date. You can set the value to the current date by going to $Flow > Current Date.
The second part of this decision will determine if the status has been changed.
If the record was updated we want to see what stage the record was updated to.
In this case, I have stages 0 - 5 and our conditions are checking what stage our record was updated to.
When a stage has been updated we want an assignment to stamp its correlating Time Stamp.
We set this the same way as the Initial Stage Time Stamp. $Record > Stage equals current date.
Following the update of the Stage 2 Time Stamp, we now have the option to ask the question: Was a stage skipped in the updating of this record?
In this case, we do this by seeing if our prior stage was the 0 Stage (Qualification)
If true then we want to update the skipped stage with the current date.
Not always will reps go smoothly through the sales process and we must account for this with a decision to check for multiple skipped stages.
In this case, if the prior records stage was 0 we know it has skipped 2 stages.
If the Prior records stage was set to 1, we know only one stage was skipped.
If both stages were skipped, we need to update both stages' Time Stamps.
If only one stage was skipped we only update Stage 2 in this case
Finally, at the end of our flow, we use the Update Record Element to use those assignments to update the record.
We want to use the IDs and field values from our current record assignments.
The Formula field should have the future stage - the past stage
Optionally we can add some formula fields to count the number of days between stages
Now your last step is to throw them on the page layout and test to make sure everything has been set up correctly.
There are many other ways that these date stamps come in handy, and probably examples that we have not experienced yet. What we can say for sure is that the only way to realize the benefits is to start capturing the data now and see the benefits in the future.