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 / Server Response ETAG m...
Power Apps
Unanswered

Server Response ETAG mismatch (Conflicts exist with changes on the server, please reload)

(0) ShareShare
ReportReport
Posted on by

Hello,

 

I have read some of the other posts on this where patch functions are interfereing with submit functions. However, I am only using a patch function when this error occurs, and I'm wondering if I'm using it incorrectly, perhaps you can help! My app logs what jobs operators are doing.

 

I have a form which I use submit form to create a record in sharepoint (to start the job). At the same time I patch some info to a separate data source (this seems to work fine) using the following function:

 

SubmitForm(Form_job_running);
Refresh('Production Database');
Patch('Production Database', First(Filter('Production Database',ID=Value(DataCard_jobID.Text))),
	{
 status: "Running",
 Job_Start: Now()
	}
 );
UpdateContext({JobRunning:true});
Patch('Production Data Times',
	 {
 Job_MO: label_jobmo.Text,
	 Start: Now(),
 Job_ID: DataCard_jobID.Text,
 job_pause_count: DataCardValue5_1.Text,
 Operator: dropdown_user.Selected.Value
	 }
 )

Then when I want to pause the job I get the error (sometimes) using the following:

 

Patch('Production Data Times', First(Filter('Production Data Times',Job_ID=DataCard_jobID.Text, job_pause_count=DataCardValue5_1.Text,End=Blank())),
	{End: Now(),
 Operator: dropdown_user.Selected.Value
	}
);

Patch('Production Database',First(Filter('Production Database',ID=Value(DataCard_jobID.Text))),
 {
 Description: DataCardValue22.Text,
 Job_MO: label_jobmo.Text,
 customer_part_num: label_custpartnum.Text,
 Job_Type: Label_job_type_1.Text,
 Booth_number: label_boothnumber_1.Selected.Value,
 Cycles_Number: Value(DataCard_cycles_number.Text),
 parts: Value(DataCardValue1_1.Text),
 operators_total: Value(Dropdown1_1.Selected.Value),
 status: "Paused",
 overtime_hours: Value(DataCardValue9_1.Text),
 reworked_parts: Value(DataCardValue14_1.Text),
 Lab_Qualification_Number: DataCardValue15_2.Text,
 cycletime_secs: Value(TextInput_cyclesecs_1.Text),
 cycletime_mins: Value(TextInput_cyclemins_1.Text),
 guntime_endhours: Value(TextInput_endgunhours_2.Text),
 guntime_endmins: Value(TextInput_endgunmins_2.Text),
 guntime_starthours: Value(TextInput_startgunhours.Text),
 guntime_startmins: Value(TextInput_startgunmins.Text),
 engineering_comments_checkbox: slider_engineering_comments.Value,
 engineering_feedback: DataCardValue13_1.Text,
 launchpad_checkbox: slider_launchpad_comments.Value,
 job_pause_count: DataCardValue5_1 +1
 }
 );

Please can you tell me if there's a better way to do this and how to avoid the error I'm getting? Should I be using the update function?

 

Thank you 🙂

 

 

Categories:
I have the same question (0)
  • Community Power Platform Member Profile Picture
    on at

    Hi @Anonymous,


    Can you provide more detail on how you "pause the job?" Is this a separate button? If so, adding a Refresh before the Patches as so should do the trick:

     

    Refresh('Production Data Times');
    Patch('Production Data Times', First(Filter('Production Data Times',Job_ID=DataCard_jobID.Text, job_pause_count=DataCardValue5_1.Text,End=Blank())),
    {End: Now(),
    Operator: dropdown_user.Selected.Value
    }
    );
    
    Refresh('Production Database');
    Patch('Production Database',First(Filter('Production Database',ID=Value(DataCard_jobID.Text))),
    {
    Description: DataCardValue22.Text,
    Job_MO: label_jobmo.Text,
    customer_part_num: label_custpartnum.Text,
    Job_Type: Label_job_type_1.Text,
    Booth_number: label_boothnumber_1.Selected.Value,
    Cycles_Number: Value(DataCard_cycles_number.Text),
    parts: Value(DataCardValue1_1.Text),
    operators_total: Value(Dropdown1_1.Selected.Value),
    status: "Paused",
    overtime_hours: Value(DataCardValue9_1.Text),
    reworked_parts: Value(DataCardValue14_1.Text),
    Lab_Qualification_Number: DataCardValue15_2.Text,
    cycletime_secs: Value(TextInput_cyclesecs_1.Text),
    cycletime_mins: Value(TextInput_cyclemins_1.Text),
    guntime_endhours: Value(TextInput_endgunhours_2.Text),
    guntime_endmins: Value(TextInput_endgunmins_2.Text),
    guntime_starthours: Value(TextInput_startgunhours.Text),
    guntime_startmins: Value(TextInput_startgunmins.Text),
    engineering_comments_checkbox: slider_engineering_comments.Value,
    engineering_feedback: DataCardValue13_1.Text,
    launchpad_checkbox: slider_launchpad_comments.Value,
    job_pause_count: DataCardValue5_1 +1
    }
    );

     

  • Community Power Platform Member Profile Picture
    on at

    Hello,

     

    Thank you very much for your response. I will try that.

     

    Yes the pause button is separate. Please can you comment on whether the patch command is the bes for this scenario? I've read in other posts (such as https://powerusers.microsoft.com/t5/General-Discussion/Server-Response-ETAG-mismatch-Conflicts-exist-with-changes-on/m-p/131599#M45805 that using updateif might be better?)

     

    Thanks for your help 🙂

  • Community Power Platform Member Profile Picture
    on at

    Hello,

     

    Unfortunately adding the refresh before the patch didn't work. However I've since tried changing the item property of the form. Instead of being LastSubmit, I've writted a context variable duing the SubmitForm function and use this with a filter to find the correct item. So far it seems to be working but this was an intermittent problem before so I will reserve judgement until its been tested for a few days.

     

    Thanks again!

     

    Max

  • Community Power Platform Member Profile Picture
    on at

    Hi @Anonymous, did that solve your problem?

     

    I am facing the same issue. Patching a record immediately after submit using lastsubmit.

  • Community Power Platform Member Profile Picture
    on at

    @Anonymous 

    @Anonymous 

    Hi guys,

     

    I have almost the same problem.

    Even if you patch an item twice it gives the same error. but it you patch an item then patch another one, afterward there is no error for patching the first one.

    I tried to refresh the database but didn't worked.

    Any comment?

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 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard