Introduction
Power Apps Formulas Deep Dive: ForAll(), Sequence(), and Concurrent()
Power Apps provides several powerful functions for working with tables, generating dynamic records, and improving app performance. Among them, ForAll(), Sequence(), and Concurrent() are especially useful when building scalable and responsive canvas apps.
Although these functions can be used independently, combining them can unlock powerful patterns for bulk operations, dynamic processing, and faster app initialization.

1. ForAll() — Perform an Action for Every Record
The ForAll() function evaluates a formula for each record in a table.
Syntax
ForAll(
Table,
Formula
)Example
Suppose we want to collect the email addresses of all active users:
ForAll(
Filter(
Users,
Active = true
),
Collect(
colEmails,
Email
)
)
Here, ForAll() iterates through every record returned by the Filter() function and performs the specified operation.
Common Use Cases
ForAll() is useful for:
Updating multiple records
Creating multiple SharePoint items
Processing records individually
Sending notifications for multiple records
Performing calculations for every record
Building collections dynamically
Bulk Update Example
ForAll(
Gallery1.AllItems,
Patch(
IT_InvoiceDetails,
ThisRecord,
{
Status: "Updated"
}
)
)This updates every record displayed in Gallery1.
Important Consideration
ForAll() is primarily intended for performing an operation on each record. When the formula produces results, Power Apps can return a table of those results, but you should not assume that the results are processed in a particular order.
Also, when working with SharePoint or other external data sources, be careful with large ForAll() operations because every Patch() or connector operation can result in network activity.
2. Sequence() — Generate Dynamic Numbers
Sequence() creates a single-column table containing sequential numbers.
Syntax
Sequence(
Count,
Start,
Step
)
The parameters are:
| Parameter | Description |
|---|---|
| Count | Number of records to generate |
| Start | Starting number; default is 1 |
| Step | Increment between numbers; default is 1 |
Example: Generate 1 to 10
Sequence(10)
Result:
1
2
3
4
5
6
7
8
9
10
The generated column is named Value.
Example: Generate Numbers from 2 to 20
Sequence(
10,
2,
2
)
Result:
2
4
6
8
10
12
14
16
18
20
Creating Dynamic Steps
You can combine Sequence() with ForAll() to execute an operation a specific number of times.
ForAll(
Sequence(5),
Patch(
IT_Tasks,
Defaults(IT_Tasks),
{
Title: "Task " & Value,
Status: "New"
}
)
)
This creates five task records.
Common Use Cases
Sequence() is useful for:
Generating row numbers
Creating dynamic test data
Building pagination controls
Generating wizard steps
Creating numeric ranges
Creating repeating records
Driving loops when there is no existing table
3. Concurrent() — Run Independent Operations in Parallel
Concurrent() allows multiple formulas to execute concurrently rather than waiting for each formula to complete sequentially.
Syntax
Concurrent(
Formula1,
Formula2,
Formula3
)
For example, an app may need to load data from several independent sources during startup.
Instead of:
ClearCollect(
colUsers,
Users
);
ClearCollect(
colOrders,
Orders
);
ClearCollect(
colProducts,
Products
);
You can use:
Concurrent(
ClearCollect(colUsers, Users),
ClearCollect(colOrders, Orders),
ClearCollect(colProducts, Products)
)
The independent operations can execute concurrently, potentially reducing the time required to initialize the screen.
Common Use Cases
Concurrent() is particularly useful for:
Loading multiple independent data sources
Initializing several collections
Running independent calculations
Improving screen startup performance
Reducing unnecessary sequential waiting
Important Rule
Only put independent operations inside Concurrent().
For example, this is unsafe if Formula2 depends on the collection created by Formula1:
Concurrent(
ClearCollect(colUsers, Users),
ClearCollect(
colUserOrders,
Filter(
Orders,
UserID in colUsers.ID
)
)
)
The second operation should not depend on the first operation completing.
4. Combining ForAll(), Sequence(), and Concurrent()
The real power comes from combining these functions appropriately.
Consider a scenario where an application needs to create five tasks and then refresh independent data sources.

Join the conversation! Your thoughts help the community grow.