Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

View all the Fabric Data Days sessions on demand. View schedule

Reply
p_da
Helper I
Helper I

For Each in a Data Pipeline

Hey folks, 

 

I'm facing an issue with a ForEach in a Data pipeline. I have configured the For Each to run in parallel (maximum 3). The ForEach has as input a Lookup activity where there is only unique values per ID. However, I have noticed that in the ForEach activity it is running twice or more for the same unique ID. Does anyone knows how can I solve it ?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @p_da ,

I think you can try these two steps below:

1. Make sure that the input array of the ForEach activity does not contain duplicate values. Sometimes, due to joins or other operations, the Find activity may return duplicate rows.
2. since ForEach is set to run in up to 3 parallel runs, make sure that the isSequential property is set to false. this setting allows for parallel execution, but can sometimes lead to unexpected behavior if not properly configured. As a temporary solution, you can set the isSequential property to true and see if the problem persists.

vyilongmsft_0-1724637576718.png

If you want more information, you can check out this official document: ForEach activity - Azure Data Factory & Azure Synapse | Microsoft Learn

 

 

 

Best Regards

Yilong Zhou

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @p_da ,

I think you can try these two steps below:

1. Make sure that the input array of the ForEach activity does not contain duplicate values. Sometimes, due to joins or other operations, the Find activity may return duplicate rows.
2. since ForEach is set to run in up to 3 parallel runs, make sure that the isSequential property is set to false. this setting allows for parallel execution, but can sometimes lead to unexpected behavior if not properly configured. As a temporary solution, you can set the isSequential property to true and see if the problem persists.

vyilongmsft_0-1724637576718.png

If you want more information, you can check out this official document: ForEach activity - Azure Data Factory & Azure Synapse | Microsoft Learn

 

 

 

Best Regards

Yilong Zhou

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

jwinchell40
Super User
Super User

@p_da - Is it possible for you to show/share the logging so we can see this in action?  From the description itself it is hard to offer up anything meaningful.

Helpful resources

Announcements
November Fabric Update Carousel

Fabric Monthly Update - November 2025

Check out the November 2025 Fabric update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.