My Account | Internet Creations
Welcome, Guest.

Use keywords in Case Subject or Description to update fields

Summary

With just standard functionality, Admins can enter a list of keywords that if found in Case Subjects or Descriptions will automatically update fields or execute actions. Automatically doing so brings urgent cases to user's attention more quickly and eliminates the need to screen cases for urgency. This article provides the Custom Field, Workflow Rules, and sample Field Updates for use with the Case object.

Details

In this example, we will automatically update a Case's Priority to the highest level if the words 'urgent', 'password', 'down', 'emergency', or 'internal server error' are mentioned in the Case Subject or Description. 
  1. Create the new Case custom field.​​
    • Navigate to Setup | Case | Fields  and click the New button at the top of the Case Custom Fields Fields & Relationships section.
                                       User-added image
  •  Select Text Area (Long) as the field type and click Next.  
  •  In the Field Label field, type "Subject and Full Description".
  •  Change the Length field to 32,255 to ensure the field will be long enough to capture all applicable information. ​
  •  Click Next. 
​                                       User-added image
  • Uncheck all 'Visible' and 'Read Only' boxes for all profiles, except leave System Administrator with 'Visible' checked. Click Save
                                        User-added image  
  • Uncheck all boxes so the field is not added to any Page Layouts and click Save
​Now we are ready to create a Workflow Rule to populate the field just created with the Case Subject and Description and another Workflow Rule to search for keywords. 
  1. Create the first workflow rule. ​
  • Navigate to Setup | Create | Workflow & Approvals | Workflow Rules and click New Rule.
  • Select Case as the object, and click Next
                                        User-added image
  • Enter "Case: New Case Populates Subject and Full Description" as the Rule Name
  • Enter a Description. We recommend: "When a case is created with a Subject or Description, the 'Subject and Full Description' field is populated."
  • Select 'Created, and every time it's edited' as the Evaluation Criteria
  • Select 'Case: Subject' for the first line of Fields and 'Case: Description' for the second line. 
  • Select 'not equal to' for both Operator choices and leave the Values blank.
  • Click 'Add Filter Logic' and type '1 OR 2'. 
  • Click Save & Next
                User-added image
        2.  Create the Field Update to populate the 'Subject and Full Description Field'.
  • In the Add Workflow Action picklist, select New Field Update
                                           User-added image
  • Enter "Populate Subject and Full Description" for the Name and tab down to populate the Unique Name. We suggest entering a Description such as "Concatenates the Subject and Full Description to autofill the Subject and Full Description field."
  • Open the Field to Update list, select 'Subject and Full Description. 
  • In the Specify New Field Value section choose Use a formula to set the new value radio button and enter this: Subject + " " + Description
                                               User-added image
  • Click Save and then click Done
  • Lastly, click the Activate button to make your rule active. 
                   User-added image

Our Second Workflow Rule will be used for updating the desired fields based on finding keywords found in the new Case Subject and Full Description field. 
  1. Create the workflow rule to search for defined keywords. ​
  • Navigate to Setup | Create | Workflow & Approvals | Workflow Rules  and click New Rule.
  • Select Case as the object, and click Next
​                                         User-added image
  • Enter a "Case: Keywords to Update Priority" as the Rule Name (change to what is most appropriate if updating field other than Case Priority).  
  • Enter a Description. Adjust as needed for the fields being updated, but we recommend "Searches the case subject and description (via "Subject and Full Description Field" field) for keywords that would warrant automatically changing the Priority to 'Service Affecting'."
  • In the Evaluation Criteria section, choose the third option 'created, and anytime it's edited to subsequently meet criteria'.
  • In the Rule Criteria section, change the first drop-down from 'criteria are met' to 'formula evaluates to true'. 
  • The screen will automatically refresh with a new long text field to enter the rule criteria formula. 
  • Enter a formula like the one below to search for the keywords you want to trigger the field update: 
    Contains(LOWER( Subject_and_Full_Description__c ),"urgent") || 
    Contains(LOWER( Subject_and_Full_Description__c ),"password") || 
    Contains(LOWER( Subject_and_Full_Description__c ),"down") || 
    Contains(LOWER( Subject_and_Full_Description__c ),"emergency") || 
    Contains(LOWER( Subject_and_Full_Description__c ),"internal server error")
In the example above, if the Subject or Description contains the words 'urgent', 'password', 'down', 'emergency', or 'internal server error' (in upper or lower case), then update the Priority field. You can change/add/remove words, just ensure the last line format stays the same and all lines above end with II
  • Click Save
​                                         User-added image

       2. Create a Field Update to change the Case's Priority.
  • In the Add Workflow Action list, select New Field Update
                              ​User-added image
  • Enter a Rule Name with the field value you are changing it to, like "Change Priority to Service Affecting". Enter a Description similar to "Changes the Case Priority field to the most urgent value, Service Affecting." with the 'Service Affecting' instead being the name appropriate for your values. 
  • Select Priority in the Field to Update list. 
  • A new option will appear below to select the Picklist Options. Choose the 'A specific value' option and select the most important/urgent Priority option. 
  • Click Save.
​                               User-added image
  • Click Save and then click Done
  • Lastly, click the Activate button to make your rule active. 
          User-added image


Please note: This KB article is provided as-is and customization using Workflow Rules is not supported.
For further assistance, please contact your Salesforce administrator, Salesforce implementation partner, or your Internet Creations Account Executive to inquire about professional services.

Support

Open a Case