---
schema_version: "1"
id: 21812be8aa5c08eaa4993b99dbdfb998f5b8d119f739f2b4b06a673be8e68b31
title: Use Cases for Prioritizing Field Service Appointments
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/service/264-0-0/pfs_scheduling_priority_optimization_use_cases.md
canonical_url: https://help.salesforce.com/s/articleView?id=service.pfs_scheduling_priority_optimization_use_cases.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 272f4a948e29d4ee4a256fec32dd226623ab127564a579469401def4cef8e49f
description: Effective prioritization is crucial in Salesforce Field Service to optimize resource allocation when your team's capacity is limited. Review the use cases to learn how to define service appointment priorities and make sure that the most critical work is addressed promptly.
products:
  - Field Service
release: "264"
---
# Use Cases for Prioritizing Field Service Appointments

Effective prioritization is crucial in Salesforce Field Service to optimize resource allocation when your team's capacity is limited. Review the use cases to learn how to define service appointment priorities and make sure that the most critical work is addressed promptly.

Salesforce Field Service supports a priority scale of 1-100. However, we recommend that you start with the default 1-10 scale. This range provides enough granularity for most use cases and simplifies the initial configuration.

You can set service appointment priority using various methods.

- Formulas–Create formula fields on the Service Appointment object to calculate priority based on other data.
- Automation–Employ tools like Flow or Apex code to dynamically update the priority.

Formula field examples are used here for clarity, but the underlying principles apply also to automation-based approaches.

## Example 1: (Basic) Prioritizing by Due Date

A company wants to prioritize service appointments based only on how soon they're due, using a more detailed priority breakdown.

- Appointments due within one day receive priority 1 (highest).
- Appointments due within three days receive priority 2.
- Appointments due within five days receive priority 3.
- Appointments due within seven days receive priority 4.
- Appointments due within 14 days receive priority 5.
- All other appointments receive priority 6 (lowest).

Use this formula to ensure timely completion of appointments, adherence to service level agreements (SLAs), and get a more granular prioritization based on `DueDate` (a standard field on the Service Appointment object).

```
IF( DueDate - TODAY() < 1, 1,
  IF( DueDate - TODAY() < 3, 2,
    IF( DueDate - TODAY() < 5, 3,
      IF( DueDate - TODAY() < 7, 4,
        IF( DueDate - TODAY() < 14, 5, 6)
      )
    )
  )
)
```

## Example 2: (Intermediate) Prioritizing by Work Type

A company wants to prioritize service appointments based on the type of work being performed.

- Emergency Repair receives priority 1 (highest).
- Installation receives priority 2.
- Preventive Maintenance receives priority 4.
- Routine Inspection receives priority 5.
- Any other work type receives priority 10 (lowest).

Use this formula to ensure that critical work types are prioritized based on the `WorkType.Name` (a standard field on the Work Type object), optimizing resource allocation and minimizing downtime.

```
CASE(WorkType.Name,
  "Emergency Repair", 1,
  "Installation", 2,
  "Preventive Maintenance", 4,
  "Routine Inspection", 5,
  10
)
```

## Example 3: (Intermediate) Prioritizing by Combined Due Date and Work Type

A company schedules installations (high priority), maintenance (medium priority), break-fix (high priority), and field inspections (low priority). While break-fixes and installations are generally prioritized, approaching due dates can increase the urgency of other work types.

- Work type priority (derived from `WorkType.Name` using `CASE`) has a 70% weight. Due date has a 30% weight.
- Due dates closer to today result in a higher priority contribution.

Use this formula to ensure a final priority between 1-10. This formula balances the inherent priority of work types with the need to meet deadlines, optimizing resource allocation and customer satisfaction based on `DueDate` (a standard field on the Service Appointment object) and `WorkType.Name` (a standard field on the Work Type object).

```
ROUND(
  CASE(WorkType.Name,
    "Emergency Repair", 1,
    "Installation", 2,
    "Preventive Maintenance", 4,
    "Routine Inspection", 5,
    10
  ) * 0.7 +
  (11 - IF( DueDate - TODAY() < 2, 10,
        IF( DueDate - TODAY() < 7, 7, 4)
      )
   ) * 0.3
, 0)
```

## Example 4: (Advanced) Prioritizing by Asset Availability and Due Date

A manufacturing service company wants to prioritize work based on asset availability (downtime impact) and due dates.

- Asset availability (70% weight) and due date (30% weight) each contribute to the final priority. Lower asset availability increases priority.

Use this formula to ensure a final priority between 1-10. Minimize downtime for critical assets and ensure timely completion of work, balancing these two important factors based on`DueDate` (a standard field the Service Appointment object) and the `Availability` field derived from the related asset. Asset availability is the percentage of expected uptime that an asset is available for use. Because there’s no standard lookup field on the Asset object, we assume one was created for this example. To create custom lookup fields, see [Create a Custom Field](https://help.salesforce.com/s/articleView?id=platform.adding_fields.htm&type=5&language=en_US).

```
ROUND(
   ((101 - Asset__c.Availability) / 10) * 0.7 +
   (11 - IF(DueDate - TODAY() < 3, 10,
         IF(DueDate - TODAY() < 7, 7, 4)
       )
    ) * 0.3
, 0)
```

## Example 5: (Advanced) Prioritizing by Account Tier and Due Date

A service company wants to prioritize service appointments based on the value of the customer's account and the due date.

- Account tier priority (derived from `Account.Account_Tier__c` using `CASE`) has a 70% weight, and due date has a 30% weight.
- Diamond accounts receive priority 1 (highest).
- Platinum accounts receive priority 2.
- Gold accounts receive priority 4.
- Silver accounts receive priority 7.
- All other acounts receive priority 10.
- Due dates closer to today result in a higher priority contribution. In this case, if the work is due in the next two days, the priority is high, if the work is due in the next seven days, the priority increases by a smaller margin, and if the work is due after seven days, it isn’t prioritized.

Use this formula to ensure a final priority between 1-10. Provide premium service to high-value customers and ensure timely completion of all work. Balance customer value and urgency based on `DueDate` (a standard field the Service Appointment object) and `Account.Tier__c` (a custom picklist field on the Account object with values: Diamond = 1, Platinum = 2, Gold = 4, Silver = 7). Because there's no standard Account Tier picklist field on Accounts, we assume one was created for this example. To create custom lookup fields, see [Create a Custom Field](https://help.salesforce.com/s/articleView?id=platform.adding_fields.htm&type=5&language=en_US).

```
ROUND(
   CASE(Account.Account_Tier__c,
     "Diamond", 1,
     "Platinum", 2,
     "Gold", 4,
     "Silver", 7,
     10
   ) * 0.7 +
   (11 - IF(DueDate - TODAY() < 3, 10,
         IF(DueDate - TODAY() < 7, 7, 4)
       )
    ) * 0.3
, 0)
```