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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Error updating SharePo...
Power Apps
Answered

Error updating SharePoint llist by using Update

(0) ShareShare
ReportReport
Posted on by 100

Hi,

 

I'm getting an error updating a SharePoint list using the Update statement.

The error is:

ErrorKind.GeneratedValue:  An attempt was made to change a column that the data source generates automatically.

The error in on the column ID.  I understand the message, but I don't know how to avoid it.

 

In the app I do this:

Saving the old version of a record:

UpdateContext({ChangeExpenseRecord:First(Filter(Expenses;ExpenseId=EntryExpenseId))})

Later in the app:

Update(Expenses;First(Filter(Expenses;ExpenseId=EntryExpenseId));ChangeExpenseRecord)

This generates the error.

In the docs I read the following:

"If the data source generates a column's value automatically, the value of that column must be reaffirmed."

I don't know what it means or what I have to do.

 

Any ideas to solve this issue?

Thanks in advance

 

 

 

Categories:
  • Verified answer
    v-siky-msft Profile Picture
    Microsoft Employee on at

    @RonHappel,

     

    The Update function will replace an entire record in a data source that is not suitable for your case.

    You can not patch or update the entire record to the data source, because some of the fields are not editable, you should modify one or more fields instead of the entire record by Patch function.

    Reference: Update Patch 

    Sik

     

  • RonHappel Profile Picture
    100 on at

    Thanks,

     

    I thought it makes the update a bit easier. I've changed the code and it works fine.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 345 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 312

#3
Mohsin Ali Profile Picture

Mohsin Ali 252

Last 30 days Overall leaderboard