Tracking Days in Status Sample

Tracking Days in Status

The number of daes that a lead sits at a specific status can be captured by a process with a daily timer. A separate custom field is used to store the number of days on each stage, so you will need to create those custom fields prior to creating the process.

Step 1 – Drag the Start Event to the diagram

Select the Opportunities base module and set the record type to New Records Only. This process will use an internal timer to count the days, so existing record updates are not desired.

Step 2 – Drag the Intermediate Timer Event to the diagram and connect

The timer will be set to 1 day.

Step 3 – Drag the Task to the diagram and connect

Set the operation to Load Module and the Module to Opportunities. The Source ID is set to [ID] so that it will load the record that started the process.

The Field Prefix can be left blank so that the values are loaded into the process variables.

The field list can be left blank so that all fields are loaded.

Step 4 – Drag a Exclusive Gateway to the diagram
Step 5 – Drag a Task to the diagram

One task will be need for each status of the opportunity. Each task will have the Save Module for Opportunities and use ID as the source. The expression will increment the appropriate field for the current stage value. For example, when the sales stage is Prospecting, DAYS_PROSPECTING_C is set to the expression:

DAYS_PROSPECTING_C + 1
Step 6 – Connect the gateway to each of the tasks and specify the filter

For each task, the connecting path should have the appropriate filter. For the first task, set SALES_STAGE == “Prospecting”.

Step 7 – Drag the End Event to the diagram, and connect

The end event has no settings and this path from the gateway will not have an expression so that it will be the default.