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 / Patch function error w...
Power Apps
Unanswered

Patch function error when patching person display name when 2 people have the same First and last names but different email id's

(0) ShareShare
ReportReport
Posted on by

Hello Community,

I have defined a person column in the SharePoint, I have used the Combo to pull the names from Microsoft365 employee names 

when I search with employee name Jon hernandez, the Combo box is showing 2 suggestions for Jon Hernandez(Their emails are like Jon.her@xyz.com,Jon.her-1@xyz.com ) when I click on save it is throwing the below error.

Error
Network error when using Patch function: The requested operation is invalid.

when I use a different name if the combo box give a single suggested name it is saving perfectly.


This is my Patch Function:

Patch(
        'THKL-MasterFile',
        ForAll(
            Gallery2.AllItems,
            {
                EmployeeName: {
                    '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
                    Claims: "i:0#.f|membership|" & EmployeeNameCard.Selected.DisplayName,
                    Department: "",
                    DisplayName: EmployeeNameCard.Selected.DisplayName,
                    Email: EmployeeNameCard.Selected.Mail,
                    JobTitle: "",
                    Picture: ""
                },


Can someone please help with this.

Thanks in advance.

Categories:
I have the same question (0)
  • v-jefferni Profile Picture
    on at

    Hi @Harika_1 ,

     

    Maybe you can also try below:

    Patch(
     'TC-MasterFile',
     ForAll(
     Gallery2.AllItems,
     {
     EmployeeName: {
     Claims: "i:0#.f|membership|" & EmployeeNameCard.Selected.Mail,
     Department: "",
     DisplayName: "",
     Email: EmployeeNameCard.Selected.Mail,
     JobTitle: "",
     Picture: ""
     },
     }
     )
    )

     

    Best regards,

  • v-jefferni Profile Picture
    on at

    Hi @Harika_1 ,

     

    If the person column in SP list doesn't allow multiple selections, the Combo box in your App should not allow either.

     

    Best 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

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
Kalathiya Profile Picture

Kalathiya 403

#2
WarrenBelz Profile Picture

WarrenBelz 338 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 320 Super User 2025 Season 2

Last 30 days Overall leaderboard