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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Fetch user name from S...
Power Apps
Answered

Fetch user name from SharePoint to be displayed in PowerApps label

(0) ShareShare
ReportReport
Posted on by 35

Hi All - I have created a simple app. It looks something like this - 

helloarry_0-1706145202406.png

I am fetching Reviewers from a SharePoint list to populate the label. list looks something like this - 

helloarry_2-1706145888180.png

Query used - 

"Reviewers: " & Concat(Filter([@'ADM Reviewers'],'Current Reviewer'),Reviewer.DisplayName,"; ")

 

Now i have to reference a different SharePoint list. It looks something like this -

helloarry_1-1706145546994.png

I have to get all the Approvers (type - Person or Group and allows multi value) where ScheduleStatus is yes. I tried below query and obviously my query did not work, i am guessing due to Approver field being a multiple value field

"Reviewers: " & Concat(Filter([@'ADM Reviewers'],'ScheduleStatus'),Approvers.DisplayName,"; ")

 

Need some help fixing this query. Thank you all !

and did i mention that i am very new to Apps 🙂

 

 

Categories:
I have the same question (0)
  • BDallas Profile Picture
    74 on at

    @helloarry you can try:

    "Reviewers: " & Concat(Filter([@'ADM Approvers'], ScheduleStatus = true), Approvers.Value, "; ")

    This query filters the ADM Approvers list only to include items where ScheduleStatus is true and concatenates the values of the Approvers field into a single string separated by semicolons. Note that the Value property is used instead of DisplayName since the Approvers field is a Person or Group.

     

     Let me know if this works for you. @ me in replies, or I'll lose your thread!!!  
    Note: 
    If this post is helpful, please mark it as the solution to help others find it easily. Also, if my answers contribute to a solution, show your appreciation by giving it a thumbs up
  • helloarry Profile Picture
    35 on at

    Hi @BDallas  , first of all thank you.

    That somehow did not work. in two ways

    One - The filter itself did not work. just don't know why. I even created a new field for the flag but it gave me a delegation warning and pulls up all the data rom the list . Flag field is a calculated field which returns the data in true or false

    helloarry_0-1706282558264.png

    helloarry_1-1706282951552.png

     

    I used "DateOfReview" field for testing as its a simple single value field to test the filter. "FlagTest" is a yes or no field and it still brings up all the dates instead of just one. I tried below syntax - 

    Concat(Filter([@'ADM Reviewer Schedule'], FlagTest ), DateOfReview, "; ") --> this one gave all the dates from the list

    Concat(Filter([@'ADM Reviewer Schedule'], FlagTest = true), DateOfReview, "; ") this one did not return anything

    2nd issue

    "Reviewers: " & Concat(Filter([@'ADM Reviewer Schedule'], ScheduleStatus = true), Approvers.Value, "; ")

    Approvers.Value - did not work. 

    Remember Approvers is a multivalve person field. 

    When i use this field in power flow, i had to do 2 loops to get the name. one loop to get to the row and another loop to loop over the Approver filed itself to get all the names.

     

    any more ideas ?

     

     

     

     

  • Akser Profile Picture
    1,546 Moderator on at

    Shouldn't it be? 

    Approvers.DisplayName

     

  • helloarry Profile Picture
    35 on at

    @Akser  i tried that but it did not work. 

    Approvers is the multi value field of person type. May be thats y ???

  • BDallas Profile Picture
    74 on at

    @helloarry you’re getting the delegation warning because the calculated fields cannot be delegated to SharePoint, meaning the filtering operation is performed on the client instead of the server.

    To avoid this issue, you can create a new column in your SharePoint list that is not a calculated field and use it to store the value of the FlagTest field.

    Then, you can utilize this new column in your filter expression. Here’s an example:

     

    "Reviewers: " & Concat(Filter([@'ADM Reviewer Schedule'], NewColumn = true), DateOfReview, "; ")

     

    The Approvers field is a multi-value person field, and you’re having trouble getting the names of all the Approvers. Unfortunately, PowerApps does not support multi-value person fields directly, so you’ll need to use a workaround to get the names.

    One way to do this is to create a separate SharePoint list containing all the Approvers' names and then use a lookup column in your ADM Reviewer Schedule list to link to this new list.

    Then, you can use the lookup column in your filter expression to get the names of the Approvers.

    Here’s an example:

     

    "Reviewers: " & Concat(Filter([@'ADM Reviewer Schedule'], ScheduleStatus = true), ApproversLookupColumn.DisplayName, "; ")

     

    Let me know if this works for you. @ me in replies, or I'll lose your thread!!!  
    Note:
    If this post is helpful, please mark it as the solution to help others find it easily. Also, if my answers contribute to a solution, show your appreciation by giving it a thumbs up
  • Verified answer
    helloarry Profile Picture
    35 on at

    @BDallas So one part of your suggestion worked. Filter was not working due to the fact that i was using a calculated field from the SharePoint list. So as suggested by you, i created a new field and created a power automate to update the field based off of a calculation. That went well.

    On to the next issue where I need to pick up all the names from a multivalve person field from a row in a list.  I was able to make that work without creating a new SharePoint list. I used lookup to achieve that. broke it down to column level. This is what worked  -

    Concat(LookUp([@'ADM Reviewer Schedule'], CurrentReviewer).Approvers, DisplayName, "; ")

    Thank you for all the pointers which led me to the solution.

     

  • BDallas Profile Picture
    74 on at

    @helloarry I am happy to know part of my suggestions works and that you were able to solve the project. 

     

    Kindly @ me with any future needs around Power BI and Fabric.

    Please give it a kudos by clicking the Thumbs Up! It goes a long way to helping others find this solution quickly.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard