cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Kamacete
Helper III
Helper III

Get data, Create, update or delete rows in another file in sharepoint

Hi,

I'm trying to create a flow that checks the data on file A (mainDoc), and create, update or delete the different data in another file (DestinationDoc) with less columns.

 

This is what I have done.

 

1.png

2.png3.png

 

"

{
    "type""object",
    "properties": {
        "Date": {
            "Type""string"
        },
        "Name": {
            "Type""string"
        },
        "content 1": {
            "Type""string"
        },
        "content 2": {
            "Type""string"
        },
        "content 3": {
            "Type""string"
        },
        "content 4": {
            "Type""string"
        },
        "content 5": {
            "Type""string"
        },
        "content 6": {
            "Type""string"
        },
        "content 7": {
            "Type""string"
        }
    }
}

"

 

 

4.png5.png

"

{
    "type""object",
    "properties": {
        "Date": {
            "Type""string"
        },
        "Name": {
            "Type""string"
        },
        "content 1": {
            "Type""string"
        },
        "content 5": {
            "Type""string"
        },
        "content 6": {
            "Type""string"
        },
        "content 7": {
            "Type""string"
        }
    }
}
"

6.png

7.png

 

"  intersection(variables('DestinationDocs Keys'),variables('MainDocs Keys')) "

 

8.png

9.png10.png

When I test the flow, this is the error that the tool returns:

 

11.png

 

could you please help me with this?

 

thank you,

Rui

 

 

4 REPLIES 4
rsaikrishna
Community Champion
Community Champion

@Kamacete 

 

I am thinking ParseJSON Content field has wrong value. Did you type the word MainDoc?

 

5.JPG

 

Replace "MainDoc" with Current Item you find under Apply to each MainDoc".

 

Here is my example one:

6.JPG

 

Please give a try and provide your feedback.

 

Regards

Krishna Rachakonda

If my reply helped you solving the issue, please mark the reply as Accepted Solution.

Hi @rsaikrishna,

You're right. 😊 How couldn't I see that? 🙄

 

However, I get a new problem.

So, as I mentioned in my first topic, I want to delete the items in the second file that don't appear in the first, so I created a condition.

 

2.png3.png

 

this is the code inside the condition on top

4.png5.png

 

 

the problems is that at the moment the first and the second file have the same data, that means that the flow doesn't have to delete anything, but he came and try to delete and give me this error.

 

1.png

 

could you please help?
thank you for or kindly support

Rui

any help please.

Not sure what's the problem at this moment, for condition, I would suggest to check run history, and compare the exact data in that run instance.

For the sharepoint error, it's clear that the specific item was not found.

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (3,183)