Hi all,
I have a CSV file in a SharePoint Online library.
I'd like to create a FLOW that goes through each line of the CSV file and, using a bit of logic, create or update items in a list.
By example, if my CSV file is the following:
Last name;First name;Email
SMITH;Allan;a.smith@outlook.com
DOE;John;jdoe@outlook.com
If a have a list with the following:
Last name | First name | Email
DOE | John | john.doe@hotmail.com
When I run the workflow, I'd like to do the following:
The resulting list would then look like this:
Last name | First name | Email
DOE | John | jdoe@outlook.com
SMITH | Allan | a.smith@outlook.com
Is this possible ? Anyone already done something similar ?
Thanks for the help,
Emmanuel
Hi, I'm trying to use your solution but I get a strange behavior: the first 5 rows in Sharepoint list have one field empty while all the others show correctly the field value. I tried to re-run the flow starting from the same excel to update the values and I get the same result.
I checked the input and output of every step of the flow and I can find the correct value in the correct field but not in the Sharepoint list. The excel file is correct, the value in this rows are formatted correctly and are all plain text.
Any idea?
Hi, I'm trying to use your solution but I get a strange behavior: the first 5 rows in Sharepoint list have one field empty while all the others show correctly the field value. I tried to re-run the flow starting from the same excel to update the values and I get the same result.
I checked the input and output of every step of the flow and I can find the correct value in the correct field but not in the Sharepoint list. The excel file is correct, the value in this rows are formatted correctly and are all plain text.
Any idea?
Hello,
Please see this template if you want to parse a CSV without 3rd party connectors. It works even if there are commas in the data.
https://powerusers.microsoft.com/t5/Power-Automate-Cookbook/CSV-to-Dataset/td-p/1508191
For this use-case, you can insert a Filter array action after the last Select action to filter the Select output before parsing the JSON to dynamic content.
for problem #2 you can use a flow trigger "when file is created"
then check if this file is the csv converted into .xlsx and if it's the case fire the rest of the flow.
I did this on other flows and works like a charm.
Using Shell Scripts you can. Unfortunately there is no such feature in Flow yet. I use VBA macros but that involves manual intervention.
Cheers,
Aamir
can i set the power query to run twice a day?
The feature is not available right now. I had a similar issue where I paste my csv in a SharePoint folder and I managed to build a workaround.
1. Create an Excel file.
2. Use PowerQuery to read the csv from the Sharepoint.
3. Use flow to to read the queried table in Excel.
4. Update/Replace the Csv as required.
Cheers,
Aamir
You can use Parse CSV action from Plumsail Documents connector. It allows you to convert CSV into an array and variables for each column. Please read this article demonstrating how it works.
Then you can iterate through result array and create items in a SharePoint list according to your logic.
Well, on my side I'll never get to the million records...
On the other hand, I totally agree wih you @asdfaf4 about the fact that Excel file paths cannot be dynamic and that's really a pain... Hope this feature will come true one day...
2 potential problems by converting to Excel...
1. Limit of 1 million rows
2. Using Excel in flow doesn't support dynamics path and filename, you have to select the file within flow. This defeats the purpose of having a library where a flow fires when a new file being added. Highly frustrating...
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.