Skip to main content

Notifications

Community site session details

Community site session details

Session Id : Df5c+DHKepovIHlJ6fqCjk
Power Apps - Building Power Apps
Unanswered

Concat with condition

Like (0) ShareShare
ReportReport
Posted on 16 Jan 2023 11:52:42 by 15,665 Super User 2024 Season 1

Hi everyone,

 

@WarrenBelz provided a solution to the following post.

 

https://powerusers.microsoft.com/t5/Building-Power-Apps/Combine-multiple-rows-into-a-single-row-based-on-a-common-field/td-p/1892025

 

I was wondering if I could take this further and apply a condition to the concat statement?

 

In the example below, I want to combine multiple rows into a single row based on a common identifier (Role ID) and where the Active column equals “Yes”

 

example.png

 

Best regards,

Ami

Categories:
  • Ami K Profile Picture
    15,665 Super User 2024 Season 1 on 16 Jan 2023 at 21:05:07
    Re: Concat with condition

    Thanks for the solution @Drrickryp.

     

    Long shot, but is there a way to do this without filtering the source table? There could be a scenario in future where I need to concat an additional column from the same table, but without filtering on active.

     

    ClearCollect(
    
     col_ConcatEmployees,
    
     AddColumns(
    
     GroupBy(
    
     People_Data,
    
     "cr37a_role_id_display",
    
     "Data"
    
     ),
    
     "Assigned Employees",
    
     Concat(
    
     Data,
    
     new_employeename,
    
     ", "
    
     ),
    
     "People_RecordID",
    
     Text(
    
     Concat(
    
     Data,
    
     new_people_dataid,
    
     ", "
    
     )
    
     )
    
     )
    
     );

     

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on 16 Jan 2023 at 14:04:40
    Re: Concat with condition

    @Amik

    With({_items: Filter(  People_Data_Table, Active ='Yes')},

    AddColumns(
    GroupBy(
    _items,
    "Role ID",
    "Data"
    ),
    "Role",
    First(Data).Role,
    "Assigned Employees",
    Concat(
    Data,
    Name,
    ","
    )
    )

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Apps - Building Power Apps

#1
MS.Ragavendar Profile Picture

MS.Ragavendar 32

#2
Rajkumar_M Profile Picture

Rajkumar_M 16 Super User 2025 Season 1

#2
mmbr1606 Profile Picture

mmbr1606 16 Super User 2025 Season 1

Overall leaderboard
Loading started