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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Converting flat file a...
Power Automate
Unanswered

Converting flat file and performing CRUD activities against Dataverse database

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi all,

 

I will provide more context below, but at a high level I have two questions which are:

 

  1. How can I automatically convert a flat file with no extension into a format that Dataverse can consume?
  2. Once that flat file is converted, how can I perform CRUD activities on a target Dataverse database based on the data in this converted file? (explained in more detail below).

 

I have a comma delimited flat file (with no extension) with ~1000 records that comes to me from a data source once a week via SFTP and I need to automate a process to turn this flat file into some form of appropriate file for carrying out the tasks below with (excel, csv, etc).

 

The data in this converted file needs to be compared against a Dataverse database (target database) which has ~600,000 records, and CRUD activities need to be carried out accordingly. Out of these ~1000 records, ~800 might be new entries to the dataset, ~150 might be updates to existing records in the dataverse database, and ~50 could be deletions from the dataverse database.

 

I've attached a file with a sample of the data that comes through once a week via SFTP as a flat file. As you can see, there is a unique identifier string (the second column), and usually there is a field with 'RES', but sometimes this field will have 'CAN' instead (the first column). The 'CAN' marker indicates that the record should be deleted, and therefore I need to create a process to ensure this is deleted from the target database.

 

If there is a record in the file we have converted with a unique identifier string that doesn't exist in the target database, that new record should be added to the target database.

 

If there is a record in the file we have converted with a unique identifier string that matches the unique identifier string on a record in the target database, the record in the target database should be updated with the data from the converted file.

 

I would appreciate any advice you have on how to achieve these goals.

 

Thanks,

Karl

Categories:
I have the same question (0)
  • Linn Zaw Win Profile Picture
    2,996 on at

    You can parse the comma-separated file as mentioned in the blog post below (you might have to remove those filler spaces in your scenario though)

     

    In your cloud flow, you can loop through each line of the file, read the data from each column by splitting the comma, match with the data in Dataverse (by calling List rows to find the matching row) and CUD accordingly.

     

    https://www.thrives.be/dynamics-365-ce/power-automate-parse-csv-files/

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 840

#2
Valantis Profile Picture

Valantis 661

#3
Haque Profile Picture

Haque 589

Last 30 days Overall leaderboard