web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Common elements in an array

(0) ShareShare
ReportReport
Posted on by 42
I have two arrays within my Power Automate Flow coming from SharePoint List.
I need to add two compose actions 
1 - This should give me all elements in both arrays but the common elements should appear only once
2 - This should give me elements which are common in both (but show them only once)
 
  • Array1: ['Houston', 'London', 'Paris', 'Barcelona']
  • Array2: ['Seattle', 'Paris', 'Brussels', 'Rome']

For above,

1 - This will give me Houston, London, Paris, Barcelona, Seattle, Brussels, Rome  -- note Paris appears only once

2 - This will give me Paris

Thanks!

Categories:
I have the same question (0)
  • Suggested answer
    Mitanshu Profile Picture
    1,644 Moderator on at
    Common elements in an array
    1 - You can use Union expression to achieve this
     
     
     
    2 - You can use intersection expression to achieve this
     
     
     
    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If this post or my previous reply was useful in other ways, please consider giving it Thumbs Up.
     
     
  • powerappnewbie4 Profile Picture
    42 on at
    Common elements in an array
    Thank-you! This worked exactly how I wanted. 
     
    Thanks for providing links to the documentation.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 535 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 348 Moderator

#3
developerAJ Profile Picture

developerAJ 262

Last 30 days Overall leaderboard