cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Manc_Gurl
Resolver I
Resolver I

Compare Arrays and store unique values

I have a SharePoint list with a multi value person field in it called Reviewers.  I have a Flow which is manually run, when the user initiates the flow they are prompted to enter the names or email addresses of the new reviewers.  My Flow works in that it takes this information, stores it in an array variable and creates tasks etc and updates the Reviewers field in my SP list item.

 

The problem is, there is no check in place to see if the new reviewer already exists, so my Flow creates a new task for them regardless of whether they already have a task associated with this list item.

 

I'm currently storing the claims information for existing reviewers in an array variable called ExistingReviewers, I am also storing the claims information for the new reviewers in an array variable called NewReviewers.  Is there a way to compare these two variables, and not create a task if the new reviewer already exists in the ExistingReviewers variable?

1 ACCEPTED SOLUTION

Accepted Solutions
abm
Super User
Super User

Hi @Manc_Gurl 

 

Please see my YouTube Video about how to compare two arrays.

 

https://www.youtube.com/watch?v=SFlj1ykpvgM

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
Power Automate Video Tutorials

View solution in original post

2 REPLIES 2
abm
Super User
Super User

Hi @Manc_Gurl 

 

Please see my YouTube Video about how to compare two arrays.

 

https://www.youtube.com/watch?v=SFlj1ykpvgM

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
Power Automate Video Tutorials
v-alzhan-msft
Community Support
Community Support

Hi @Manc_Gurl ,

 

Have your issue been solved according to @abm   'solution?

If yes, please go ahead and mark the post as solved by clicking “Accept as Solution” so that this thread will be marked for other users to easily identify!

 

Best Regards,

Alice

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Users online (1,316)