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 in powe...
Power Apps
Suggested Answer

Patch function in power apps - error [patch has some invalid argument]

(0) ShareShare
ReportReport
Posted on by
Hey,
I am facing a issue with a patch function mentioned below

Refresh('ha.ProjectReview');
 
Patch('ha.ProjectReview',
LookUp('ha.ProjectReview', client_code = ThisItem.Client_Code && project_code = ThisItem.Project_Code),
{client_code:ThisItem.Client_Code, client:ThisItem.Client, project_code:ThisItem.Project_Code, project:ThisItem.Project, ToBeReviewed: 1, isScheduled:0, isReviewCompleted:0});
 
 

Details on the bug:


I am encountering an error in my Patch function, stating that there are invalid arguments when trying to use the table (as shown in the attached image). Here are the potential solutions I have tried:

  1. The code works in the production environment with a different SQL Server connection, but it does not work in the development environment. I have verified that there is no connection issue there.
  2. The table is utilized in Power Automate, and the flow successfully fetches rows, confirming that the connection is functional.
  3. I created a new connection and tested it, but the same error persists.
  4. It was previously working without issues, but this error has suddenly appeared.
**ha.ProjectReview - is a table 

Can anyone find a solution to this issue?

I have the same question (0)
  • Suggested answer
    Nandit Profile Picture
    1,568 Moderator on at
     
    Do you have a Primary key in your SQL Table. Is error usually occurs when that's missing. I'd suggest adding that as that might take the error away. 
     
    Hope this helps.
     
    Kind regards, 
    Nandit

    If this answers your query, please mark this response as the answer.
    If its helpful, please leave a like. Thanks!

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 765 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 272

Last 30 days Overall leaderboard