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 Automate / Update a row in SQL Se...
Power Automate
Unanswered

Update a row in SQL Server fails, because the ID for update is sent with update fields request

(0) ShareShare
ReportReport
Posted on by 10

First, it is some imcompreensible that Flow doens't have an update component allows to update a row with another fields beyond the id field. When we do complex logics with data, this is necessary.

Second, I am trying to update a row, after be obligated to go field by field, to check some condition, and when the condition is reached, and I call the update step, an error occurs because the request to update is sending the ID in the group fields that I want to update.

I think it is a component error, and nothing that could be fixed with alternate paths.

Screenshot from 2017-07-13 18-28-51.pngScreenshot from 2017-07-13 18-29-57.png

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

    Hi rodrigosaraiva,

     

    What’s the trigger of your flow? How is the id field for action “SQL – Update row” configured?

     

    To test this issue, I create a simple flow. The flow is triggered by “SharePoint – when a new item is created”, followed by the action “SQL – Update row”.


    Then create a new item to trigger the flow, if the id is already existing in SQL table, it will run succeed.


    Screenshots for the flow configuration and run details:

    3.PNG

    4.PNG

     

    Please show me more details to reproduce this issue on my side.

     

    Best regards,
    Mabel Mao

  • rodrigosaraiva Profile Picture
    10 on at

    Thank for your repply.

     

    but the problem is: I have a different structure from Sharepoint List and my database model, and this thing I can't change, because the database is receiving data from other diferent systems.

    My trigger is an existing item is modified, then I get the item, I compose an external_id (it is how I need to control the integration between the list and database table, because the ID of a list cannot be the ID of table, and this is the reason that I complain because I cannot get a table row by another field different from table ID), then I get all the rows from table, and trying to identify the table row by a condition, to do an update. Everything is right, but when the update is sent to database server an error occurs because the ID field is sent to be updated to with the modified fields, and SQL Server don't allow update the ID field. I think the error is in this point.

     

    Screenshot from 2017-07-14 10-42-21.pngScreenshot from 2017-07-14 10-52-28.png

  • v-yamao-msft Profile Picture
    on at

    Hi rodrigosaraiva,

     

    Thanks for clarification with more details.

     

    As you mentioned, SQL Server don't allow update the ID field, so you will not be able to update the row with the modified ID field.


    Best regards,
    Mabel Mao

  • rodrigosaraiva Profile Picture
    10 on at

    I think you do not understand the problem yet. I am not sending the Id field for update. I don't want modify the id field.

    The component is doing that. That is the problem.

    This update row component is sending the id for update, when is suposed to use the id only to identify the row.

     

    thanks

     

  • jakekemme Profile Picture
    11 on at

    I am having this same issue.  I'm attempting to update a row where the ID is an Identity Specification (numeric id auto incremented by the sql server).  The flow 'Update Row' action attempts to update this ID as well, which seems to be a bug as the selected row identity should never be updated.  As it stands, it seems impossible to update rows that have sql generated row identities as the primary key.

  • Community Power Platform Member Profile Picture
    on at
  • NieGreJoh Profile Picture
    23 on at

    Hi - I have also faced the same problem - trying to document how I compensated for that https://blog.hexatown.com/creating-sql-table-for-use-in-flow-and-powerapps-dd9e637caaf3

  • Community Power Platform Member Profile Picture
    on at

    Hi, I'm also hitting the same problem. The identity column should not be passed along to the update or it should include set identity on during update.

     

    Anyone has the solution? Without the fix, the SQL update row totally cannot be used.

  • asdeev Profile Picture
    on at

    Is there a solution for this?

  • jarodts Profile Picture
    28 on at

    Ugh - no fun to find a problem with no solution...

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 Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 503 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 321 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard