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 / Return true if string ...
Power Apps
Unanswered

Return true if string contains any item in collection

(0) ShareShare
ReportReport
Posted on by

Hello - I've hit a wall with this one.  I have a dataset (D1 - below) that can be formatted into a collection or a table depending on how y'all can help answer this one.  I need to filter a secondary dataset (D2 - below) depending if one of the string-type columns contains any of the items in D1.

 

Boiled Down - need function to return true if any of the D1 items (essentially substrings) are found in the D2 column string.

 

D1 Example 

["ABC-0001","ABC-0004"]

D2 Example Rows Of The Column that needs to be filtered (Data Source Name - "TASK DATA", Column Name "TEST_COL"

1. "ABC-0001"

2. "ABC-0004"

3. "ABC-0003,ABC-0007,ABC-0008"

4. "ABC-0005"

5. "ABC-0004,ABC-0005"

6. "ABC-0011"

 

Desired return: 

1. "ABC-0001"

2. "ABC-0004"

5. "ABC-0004,ABC-0005"

 

Categories:
I have the same question (0)
  • QuentinDURIEZ Profile Picture
    577 Moderator on at

    Hi,

    You could achieve this like this : 

     

    ForAll(
     D1 As d1,
     Collect(
     DResult,
     ForAll(
     Filter(
     D2 As d2,
     d1.Value in d2.Text
     ),
     ThisRecord
     )
     )
    )

     

    The idea is to use nested ForAll loop to "join" the two collections into another one.


    Collections used for reference : 

     

    QuentinDURIEZ_0-1713455639025.png

    QuentinDURIEZ_1-1713455650105.png

    QuentinDURIEZ_2-1713455659827.png

     

    Regards,

     

     

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 Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 414

#2
Valantis Profile Picture

Valantis 387

#3
timl Profile Picture

timl 344 Super User 2026 Season 1

Last 30 days Overall leaderboard