Hi everyone!
I have been trying to update items on a SharePoint column with no success. My aim is to have a Flow everyday that updates all column items with today's date.
My current flow
Any idea of what what might be going wrong? The flow runs, but noting happens to the list.
Is it the 'Description' ? Should I be using another property to update the items? Which property would I be updating to fill all cells in a column?
Solved! Go to Solution.
What you need is Get Items action step before the HTTP call and map the identifier in your HTTP action step. Flow will automatically insert a loop for the iteration. Hope it make sense.
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blog
Are there any specific reason you need use the HTTP action step? Why not use update item SharePoint action step which will be much easier.
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogI believe the problem is that you are updating the Description of the field (column) not the record values stored in the column. You need to update the values in /items, not /fields. Take a look at this walkthrough.
Update single SharePoint column in Power Automate with HTTP request (tomriha.com)
@abmActually, for the reasons enumerated in the article that shared @Pstork1. Also, I have add success with this method and lots of problems (as in flow updating fields they should not have) with that method, so I am sticking with what as worked for me.
https://tomriha.com/update-single-date-and-time-sharepoint-column-with-power-automate/
Actually this is exactly what I wanted, but I'm getting a "Input string was not in a correct format."
My input string, I think is:
_api/web/lists/getbytitle('TeamsUsage_2022-01-03_2022-04-02')/items('TodayDate')/validateUpdateListItem
TodayDate is the internal name of the column and TeamsUsage_2022-01-03_2022-04-02 is the name of the list, so I am at a loss how to format it correctly.
Sorry, totally a newbie.
Can you show what format you are using in the FormatDateTime(). It needs to be an ISO8601 format. I would suggest using the standard format of 'u' with is ISO 8601 standard sortable. That is I believe what SharePoint is expecting.
Form that article it shows how to update. See below item(1) is the item identifier of the record. In your case you are passing a string value which is wrong. You need to get the record id.
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blog
What you need is Get Items action step before the HTTP call and map the identifier in your HTTP action step. Flow will automatically insert a loop for the iteration. Hope it make sense.
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogI am using the formula utcNow('dd/MM/yyyy'), as suggested in the above, which is outputting the correct number.
The full error is here:
{
"status": 400,
"message": "Input string was not in a correct format.\r\nclientRequestId: f3434a61-2c96-4d48-b392-888536ca74c2\r\nserviceRequestId: 450a33a0-908c-4000-0aec-dd06153bd00c",
"source": "https://purplebeardltd.sharepoint.com/sites/TestingGrounds/_api/web/lists/getbytitle('TeamsUsage_2022-01-03_2022-04-02')/items('TodayDate')/validateUpdateListItem",
"errors": [
"-1",
"Microsoft.SharePoint.Client.InvalidClientQueryException"
]
}{
"status": 400,
"message": "Input string was not in a correct format.\r\nclientRequestId: f3434a61-2c96-4d48-b392-888536ca74c2\r\nserviceRequestId: 450a33a0-908c-4000-0aec-dd06153bd00c",
"source": "xxx/_api/web/lists/getbytitle('TeamsUsage_2022-01-03_2022-04-02')/items('TodayDate')/validateUpdateListItem",
"errors": [
"-1",
"Microsoft.SharePoint.Client.InvalidClientQueryException"
]
}
The syntax is
Uri: _api/web/lists/GetByTitle('<ListName>')/items(<ItemID>)/validateUpdateListItem
In your case you have
items('TodayDate')
This must be the id of the record which you are trying to update.
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogEUREKA!
That is it. I was under the impression that I could just put the column name in the input string.
Thank you very much!
If your problem has solved, please go ahead and mark the post as solved by clicking “Accept as Solution” so that this thread will be marked for other users to easily identify!
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogUser | Count |
---|---|
88 | |
39 | |
23 | |
20 | |
16 |
User | Count |
---|---|
128 | |
47 | |
46 | |
27 | |
25 |