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 : sQ+DuWwJj5t1j+w819V+Vv
Power Automate - Building Flows
Unanswered

from CSV to SharePoint list

Like (0) ShareShare
ReportReport
Posted on 19 May 2023 21:48:12 by 8

Hello everyone, 

 

I am trying to create a workflow that brings items from a CSV file located in SP to a list located in the same SP. 

mipisote_0-1684532754616.png

The Condition: length(body('Filter_array'))

What am I missing?

Your assistance is kindly appreciated.

 

Cheers, 

  • mipisote Profile Picture
    8 on 23 May 2023 at 02:19:59
    Re: from CSV to SharePoint list

    The title column is unique. 

  • Rhiassuring Profile Picture
    8,688 Moderator on 23 May 2023 at 00:09:50
    Re: from CSV to SharePoint list

    Okay, then my previous response doesn't apply at all - CSVs are totally different beasts.

     

    Do you have a unique value that is held in your XLSX, that there should be only one of? A Title? An email (ie, if there's only one line per person) or an ID (if there's a commodity code or something)? 

     

    If so, you will use that as your filter - the bottom paragraph of my post outlines the steps, give it a shot if you have unique data. If you don't, you will need to create it. (Common ways is to combine acronyms to create a unique ID. Row # won't be a unique ID in this scenario.) 

  • mipisote Profile Picture
    8 on 22 May 2023 at 23:43:26
    Re: from CSV to SharePoint list

    it is a xlsx, you are correct. 

  • Rhiassuring Profile Picture
    8,688 Moderator on 22 May 2023 at 23:36:25
    Re: from CSV to SharePoint list

    Hi there, 

     

    I'm a little confused. The Excel action - Get Rows Present in a Table - doesn't work for CSVs. I just tested it to make sure I'm not forgetting something - and, it sure doesn't work for me.

     

    Are you sure this is a CSV? Or is this just a normal Excel file? I just want to get clarification before we move forward, because if you're doing something different, different instructions may be needed.

  • mipisote Profile Picture
    8 on 22 May 2023 at 21:24:52
    Re: from CSV to SharePoint list

    Hi, 

    I tried it but now the workflow wont add new items from the CSV file. this is what I currently have:

    mipisote_2-1684790608370.png

    mipisote_3-1684790654440.png

     

     



  • Rhiassuring Profile Picture
    8,688 Moderator on 22 May 2023 at 03:44:56
    Re: from CSV to SharePoint list

    Duplicates in the CSV file itself, or duplicates as in, if it already exists in the SharePoint list? 

     

    Anyway, to get the data out of the CSV, you should look at something like this:

     

    https://www.youtube.com/watch?v=pmQkeFeSkiw

     

    Basically using the "Get File Content" action to aim at the CSV, get that content, and then use split() on new lines to split after every carriage.  Then, your commas tell you where the limits are between each columns content.

     

    The video is very well done, it will get you what you need.

     

    As for the duplications, if you want to prevent duplicates going into SharePoint (usually people will want to "Create" if it doesn't exist there, and "Update" the existing one if it does.) You will just use a "Get Items" action and Filter to the unique column for that one - like, Title, for example. You can use a condition based on length() -- if you aim the length() expression at the output from your Get Items, it will come back with 0 if empty (ie, nothing was found) and 1 if it found an item. If 0, Create Item. If Greater Than 0, Update Item -- and you can use the "ID" dynamic content that came back with the Get Items action.

  • mipisote Profile Picture
    8 on 19 May 2023 at 21:49:21
    Re: from CSV to SharePoint list

    I need to exclude any duplicates. 

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

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Announcing our 2025 Season 2 Super Users!

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading complete