cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ML147243
Helper II
Helper II

Updating file property using excel table data

I've been trying to add to add a branch to a flow and cannot get the addition to work. I would like to update the file property for "Month" with the data already be extracted from the excel file. 

I'm getting a generic failed action error. Below is my flow and the error screen. Any help is appreciated. 

update month.jpg

Month error message.jpg

  

1 ACCEPTED SOLUTION

Accepted Solutions
ML147243
Helper II
Helper II

The issue ended up being that the flow still had the excel connection in use when I was trying to update the properties. I found more details about the error in the outputs of the last failed action and it said the file was locked by me. 

 

I ended up initializing a variable for the itemID after the " Get metadata. I then passed that information on to the child flow, where I added a Delay action and then an update file properties. 

ML147243_0-1644346579053.pngML147243_1-1644346599763.pngML147243_2-1644346669155.pngML147243_3-1644346696474.pngML147243_4-1644346709412.png

 

View solution in original post

5 REPLIES 5
v-jefferni
Community Support
Community Support

Hi @ML147243 ,

 

The screenshot of the flow is too fuzzy, could you please edit the post and replace it with a clearer one? Besides, what is the result table of the Parse JSON operation?

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

ML147243
Helper II
Helper II

@v-jefferni Is this better?

ML147243_0-1644266113873.png@

ML147243_1-1644266128136.png

"type""array",
    "items": {
        "type""object",
        "properties": {
            "@@odata.etag": {
                "type""string"
            },
            "ItemInternalId": {
                "type""string"
            },
            "Class": {
                "type""string"
            },
            "Date Trained": {
                "type""string"
            },
            "Num enrolled": {
                "type""string"
            },
            "num No-show": {
                "type""string"
            },
            "Num Walk-in": {
                "type""string"
            },
            "Instructor": {
                "type""string"
            },
            "Ivanti Ticket": {
                "type""string"
            },
            "Comments": {
                "type""string"
            },
            "Reference": {
                "type""string"
            },
            "Month": {
                "type""string"
            }
        },
        "required": [
            "@@odata.etag",
            "ItemInternalId",
            "Class",
            "Date Trained",
            "Num enrolled",
            "num No-show",
            "Num Walk-in",
            "Instructor",
            "Ivanti Ticket",
            "Comments",
            "Reference"
        ]
    }
}
ML147243_2-1644266212578.png

 

ML147243_6-1644266320686.pngML147243_7-1644266331016.png

 

 
 
 

 

Hi @ML147243 ,

 

Actually I cannot understand the logic from your flow steps, you will update each file property based on all the excel file month column values? I suppose you would like to update file properties based on the ItemInternalId value from in the Excel and file ID in the library, then you will need to filter the files in the step Get files (property only) 2 action with filter query ID eq ItemInternalId, then for each filtered file update the properties based on the month value.

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

@v-jefferni I'm sorry, I forgot to add my filter in the get files. I have tried many different ways to get this to work. This is what I currently have FileLeafRef eq '@{outputs('Get_file_metadata')?['body/Name']}'. It does find the file but I get the action failed error. I will try the internal ID again.

ML147243
Helper II
Helper II

The issue ended up being that the flow still had the excel connection in use when I was trying to update the properties. I found more details about the error in the outputs of the last failed action and it said the file was locked by me. 

 

I ended up initializing a variable for the itemID after the " Get metadata. I then passed that information on to the child flow, where I added a Delay action and then an update file properties. 

ML147243_0-1644346579053.pngML147243_1-1644346599763.pngML147243_2-1644346669155.pngML147243_3-1644346696474.pngML147243_4-1644346709412.png

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Users online (2,531)