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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter based on a Tabl...
Power Apps
Unanswered

Filter based on a Table Person Field present in a Collection with a Person field

(0) ShareShare
ReportReport
Posted on by 4

I have a table "PA Weekly Activities" with a Person field (no multiple selections) called Surveyor. I also have a collection colMembers with a Person field called TeamMember (no multiple selections). I'd like a Gallery filtered on the table field Surveyor being in the collection based on the field TeamMember.

 

The 2 fields are exactly the same apart from the names, I can view the collection and see the Email of TeamMember. So, I can output the TeamMember Email address but it's the reference to a property of TeamMember within a filter that seems to be the sticking point.

 

The basic filter is:

 

Filter(
'PA Weekly Activities',
XXXXXXXXXXXXXXXX
)

 

The following lines replacing XXXXXXXXXXXXXXXX don't work for reasons of comparing Text to Record, missing TeamMember etc.

 

Surveyor in colMembers.TeamMember

Surveyor.Email = colMembers.TeamMember.Email

Surveyor in colMembers[@TeamMember]

Surveyor.Email = colMembers[@TeamMember].Email

 

I've tried dozens of alternatives but ran out of ideas. Any help would be appreciated.

Categories:
I have the same question (0)
  • Rusk Profile Picture
    1,369 Super User 2024 Season 1 on at

    Hi @abilsborough 

     

    The "in" function will work, but can only look at a single column.  You can use ShowColumns to get it to work:

     

    Filter('PA Weekly Activities',Email in ShowColumns(TeamMember,"Email"))

     

     

    Here's an example:

    Rusk_0-1677193675182.png

     

     

  • abilsborough Profile Picture
    4 on at

    Thanks for the prompt reply and example, that feels the right way to do it but still having problems referring to the Email property of TeamMember. The errors saying column Email doesn't exist. I've tried:

     

    Filter('PA Weekly Activities',Surveyor.Email in ShowColumns(TeamMember,"Email"))

    Filter('PA Weekly Activities',Surveyor.Email in ShowColumns(colMembers,"TeamMember.Email"))

    Filter('PA Weekly Activities',Surveyor.Email in ShowColumns(colMembers[@TeamMember],"Email")

     

    TIA.

  • Rusk Profile Picture
    1,369 Super User 2024 Season 1 on at

    Hi @abilsborough 

     

    I'm sorry, I forgot that your column TeamMember is a People Picker and is returning a table of the person attributes.  Can you collect only the email for your colMembers in a separate collection and then use that for reference?

  • abilsborough Profile Picture
    4 on at

    Hi, Yes that's the reason I tried a collection as I couldn't find a Filter option that worked. I thought I'd create a simple collection of emails but I'm having the same problems whether it's extracting email addresses to a collection or a filter statement. I probably should go back to a normal filter, it's all I need.

     

    BTW I can output an email from the collection as below, it just seems to be a problem with the Filter statement.

     

    TIA.

     

    abilsborough_0-1677554755761.png

     

    abilsborough_1-1677554811308.png

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 396 Most Valuable Professional

#2
11manish Profile Picture

11manish 134 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 101 Super User 2026 Season 2

Last 30 days Overall leaderboard