Skip to tutorial content
Rate module 4.0/5 (1)

Flow Logic & Data Pills

3 min read
On this page

In this lesson, you will learn:

  • What flow logic is and the most common types
  • What data pills are and how to use them
  • How data moves from step to step in a flow

1 Making decisions

Real processes aren’t a straight line. “If the manager approves, create a task. Else, tell the requester no.” That’s flow logic. πŸ”€

Flow logic What it does
If / Else If / Else Takes a different path depending on a condition
For Each Repeats steps for every item in a list
Do the following in parallel Runs several paths at the same time
Wait for a duration Pauses for a set time, like 1 day
End Flow Stops the flow

2 Data pills

Each step can use data from earlier steps. That data shows up as colorful little tags called data pills. πŸ’Š

Key term: Data pill

A piece of data from the trigger or an earlier step, like the requester’s name. You drag it into a later step.

Key term: Data panel

The panel on the right of Workflow Studio that lists all the data pills you can use.

A flow with logic and data pills. Step 1: Ask for Approval, approver is the data pill Requested for, Manager. Step 2: If the data pill Approval State is Approved. Step 3, inside the If: Create Catalog Task with short description built from the data pill Requested Item, Number. Step 4, Else: Send Email to the data pill Requested for, saying the request was rejected. On the right, the data panel lists pills from the trigger and from step 1.
Figure 1. Flow logic picks the path. Data pills carry data from step to step.

3 Using a data pill

  1. Open a step, like Send Email.
  2. Find the field you want to fill, like To.
  3. In the data panel, open the trigger’s data, like Requested Item Record.
  4. Drag the pill, like Requested for, into the field.
  5. You can also dot-walk through a pill, like Requested for > Manager > Email. βœ…

πŸ’‘ Good to know: Using pills instead of typing names makes the flow work for every record. “Requested for” is always the right person.

πŸ“ Note: “Dot-walking” means following a reference field to another table, like from a user to their manager. You’ll learn more in Lesson 31.3.

⭐ Remember: Flow logic = which path. Data pills = which data.

4 Let’s try it: add a decision

  1. Open your “SNWR P1 alert” flow from Lesson 28.2.
  2. Add If: the trigger record’s Assignment group is empty.
  3. Inside the If, add Update Record: set Assignment group to SNWR Service Desk.
  4. Use a data pill to put the incident Number into the email subject.
  5. Save and activate. Test it with a new P1 incident.

5 Quick recap

  • Flow logic: If/Else, For Each, parallel, wait, End Flow
  • Data pills carry data from the trigger and earlier steps
  • Drag pills from the data panel into fields
  • Pills can be dot-walked, like Requested for > Manager

6 Check yourself

Think of your answer first. Then tap to check.

1 You want to repeat a step for every item in a list. Which flow logic? Show answer

For Each.

2 What is a data pill? Show answer

A piece of data from the trigger or an earlier step that you drag into a later step.

3 Why use a data pill instead of typing a person’s name? Show answer

So the flow uses the right person for every record, not just one fixed name.

Nice work! You finished this lesson. πŸŽ‰

Was this lesson helpful?

Have a question or doubt?

Ask here and get help from instructors and fellow learners.

0 / 300

Only logged-in learners can post.