cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Badral
Helper I
Helper I

Apply to each action creates multiple items

Hello. I'm trying to create person's display name using send http request. When choose multiple person in one item, it duplicates that item per person. how to solve this problem. i want those multiple person name in one item.Screenshot 2021-05-06 192102.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Johnnyg
Microsoft
Microsoft

Hello Badral,

I would recommend you to have a try with the union() function to remove the duplicates. Below is the expression to do the same.

union(variables('AvailableDeviceTypes'),variables('AvailableDeviceTypes'))

Here AvailableDeviceTypes is sample array variable. union() function requires two array variables. Since I need to remove the duplicates from a single array, I pass the same array variable twice.

Blog for reference: How to remove duplicate items from an Array in Power Automate - Debajit's Power Apps & Dynamics 365 ...

Best Regards,
Johnny
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

1 REPLY 1
Johnnyg
Microsoft
Microsoft

Hello Badral,

I would recommend you to have a try with the union() function to remove the duplicates. Below is the expression to do the same.

union(variables('AvailableDeviceTypes'),variables('AvailableDeviceTypes'))

Here AvailableDeviceTypes is sample array variable. union() function requires two array variables. Since I need to remove the duplicates from a single array, I pass the same array variable twice.

Blog for reference: How to remove duplicate items from an Array in Power Automate - Debajit's Power Apps & Dynamics 365 ...

Best Regards,
Johnny
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

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Users online (57,145)