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

Community site session details

Session Id : sJ49I9u11cpE+mxRpLz2Dc
Power Automate - Building Flows
Answered

Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

Like (1) ShareShare
ReportReport
Posted on 2 Jul 2024 10:53:57 by 31
 
Hello all, 

THANKS A LOT IN ADVANCE 🧡

 

Step 1) The Items in Sharepoint Library are always like this - the field "ID" is unique 

JuliaDRX_0-1719917420512.png

 

Step 2) 

bring the Items into an existing Excel file ( which is stored on another folder in the Sharepoint)

JuliaDRX_1-1719917420375.png

 

WORKS GOOD SO FAR !

Problem: it is not checking if the "ID" already exist, and put it in again and again

 

JuliaDRX_2-1719917420530.png

 

The Flow is build up like this:

1) Recurrence : every day 

 works✔️

 

2) Dateien abrufen (nur Eigenschaften) from folder "Reparaturaufträge" 

 works✔️

 

3) Variable : Name* ID, Type:Array , Value: body/value "list of elements"

 works✔️

 

4) Choose variable: from* body/value, map* ID  = union(variables('ID'),variables('ID')) 

 HERE is the checking missing

 

 

5) For Each "body/value" >> add a row into excel file table wich is matched with every single field


 

 works✔️

JuliaDRX_8-1719917420677.png

 

 

 

 

  • JuliaDRX Profile Picture
    31 on 03 Jul 2024 at 13:20:54
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    Found my mistake 🙂 thanks for you help 

  • Verified answer
    JuliaDRX Profile Picture
    31 on 03 Jul 2024 at 13:19:30
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    JuliaDRX_0-1720106018245.png

    IT WORKS ! 

  • Verified answer
    v-yueyun-msft Profile Picture
    on 03 Jul 2024 at 07:12:53
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    Hi , @JuliaDRX 

    I create a sample test flow , you can refer to :

    The "List rows present in a table" is used to check if the [ID] exist in your Excel file!

    vyueyunmsft_1-1719990810911.png

     

     

    items('Apply_to_each')?['ID']

    length(outputs('List_rows_present_in_a_table')?['body/value'])

     

    You need to use your action name in your side.

     

    If this reply can help you , you can click mark this reply as solution (Accept solution) which can help more people, thanks in advance! 

     

    Best Regards,

    Yueyun Zhang

     

     

     

  • JuliaDRX Profile Picture
    31 on 03 Jul 2024 at 07:04:18
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    JuliaDRX_1-1719990252734.png

     

  • JuliaDRX Profile Picture
    31 on 03 Jul 2024 at 07:02:58
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    I want to add it if the ID does not exist- yes. BUT I also want no adding if the ID is already existing. 

     

    Right now I have some ID multiple time in the file - because the flow is just adding everything again and again 

    JuliaDRX_0-1719990166309.png

     

  • v-yueyun-msft Profile Picture
    on 03 Jul 2024 at 06:56:14
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    Hi, @JuliaDRX 

    Thanks for your response! 

    As in your screenshot , the [body/value] is the whole files return from your "Get files" action. So it will always unique.

    According to your description, do you mean you want to add a row to your Excel when the [ID] column do not exist in your Excel file ?

     

    Best Regards,

    Yueyun Zhang

  • JuliaDRX Profile Picture
    31 on 03 Jul 2024 at 06:51:25
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    Hi 

    Yueyun Zhang, first of all thanks for your help !

    I just took the "body/value" 

    JuliaDRX_1-1719987759160.png

     

    JuliaDRX_0-1719987690228.png

     

    JuliaDRX_2-1719987800486.pngJuliaDRX_3-1719989469381.png

     

     

  • Verified answer
    v-yueyun-msft Profile Picture
    on 03 Jul 2024 at 01:29:00
    Re: Sharepoint Library Items newest into an existing Excel File ( also stored in Sharepoint)

    Hi , @JuliaDRX 

    What's the field you put in your "Initialize variable" action?

    And can you show me a screenshot for the output of your "Select" action in your flow run history.

     

    Best Regards,

    Yueyun Zhang

     

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 2

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 2

Loading complete