In this guide:
- Okta Workflows guides
- Remove duplicates from a table
- Related Okta Workflows guides
- Okta Workflows resources
Okta Workflows guides
Okta Workflows guides are questions and answers from the community office hours, the #okta-workflows channel on MacAdmins Slack, and other places. Read all the other guides.
How to remove duplicates from a table in Okta Workflows?
This guide will teach you to remove duplicates from a table in Okta Workflows.
Remove duplicates from a table
You have the following table and need to remove duplicate department name entries from it:

The table looks like this after removing duplicate entries:

The solution has two flows.
- Remove Duplicates flow.
- Create Row flow (helper).
Remove Duplicates flow
The Remove Duplicates flow saves all table records into a list and removes duplicates from that list.

The flow has the following steps:
Table – Search Rows
In this step, the Search Rows card returns all the rows from a table in a JSON format that looks like this:
[
{
"Department Name": "Marketing"
},
{
"Department Name": "Sales"
},
{
"Department Name": "Engineering"
},
{
"Department Name": "HR"
},
{
"Department Name": "Marketing"
},
{
"Department Name": "Engineering"
},
{
"Department Name": "Engineering"
},
{
"Department Name": "Design"
},
{
"Department Name": "QA"
}
]
List – Pluck
In this step, the Pluck card produces a list only with the Department Name key. The list looks like this:
[
"Marketing",
"Sales",
"Engineering",
"HR",
"Marketing",
"Engineering",
"Engineering",
"Design",
"QA"
]
List – Remove Duplicates
In this step, the card removes duplicates from a list. The result is a list without duplicates:
[
"Marketing",
"Sales",
"Engineering",
"HR",
"Design",
"QA"
]
Tables – Clear Table
In this step, the flow clears the table before saving the list without duplicates into a table.
List – For Each
This step calls a helper flow to save the list without duplicates in a table.
Create Row flow
The Create Row flow creates a new row in a table for each item in the list.

Table without duplicates
The result is a table without duplicate values:

Related Okta Workflows guides
- How to Setup a Workflows Helper Flow (With For-Each and Streaming Cards).
- How to Delete Multiple Table Rows.
- How to Iterate Over Rows in a Table in Okta Workflows.
Okta Workflows resources
π« Get help from Workflows specialists during weekly community office hours.
πΊ Learn from Workflows videos.
π Get help from support: discuss a Workflows topic or ask a question.
ππ»ββοΈ Get help from the community: join the #okta-workflows channel on MacAdmins Slack.
Leave a comment