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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Flow For Importing Ent...
Power Automate
Answered

Flow For Importing Entire Excel Worksheet into SQL Server?

(0) ShareShare
ReportReport
Posted on by 11

Hi,

 

My goal is to create a Power Automate Flow that will allow me to retrieve a file (In my case from SharePoint) and enter the entire worksheet(s) into a SQL Server Table. I have already created the table in SQL to match the column headers and datatypes of my Excel sheet. My question is this: I have seen other posts for "List rows present in a table" and this will not work for me because I do not have a table setup within my sheet, just raw data, and therefore I cannot programmatically reference the table in my flow. If there is an option to import a CSV using Power Automate this would also be fine as I have a staging table and then cast those values to production tables with my necessary datatypes. 

 

Thanks!

Categories:
I have the same question (13)
  • Verified answer
    takolota1 Profile Picture
    4,974 Moderator on at

    @JBR15 


    Yes you can get the contents of a CSV file on OneDrive or SharePoint & transform that for SQL queries. If the file contents don’t come through as text, then you can usually use a base64tostring( ) expression on the contents to get it into text.

     

    How big are your worksheets? How many rows?


    If it is just a few, then I have something you can use to get CSV data into JSON dynamic content that you can use in a regular SQL action in a loop.

    https://powerusers.microsoft.com/t5/Power-Automate-Cookbook/CSV-to-Dataset/td-p/1508191

     

    EDIT: Here is a link to the template flow page where the author eventually got something to help with his external site report download to SQL request: https://powerusers.microsoft.com/t5/Power-Automate-Cookbook/Automate-Reports-From-External-Datasources/td-p/1486023

  • JBR15 Profile Picture
    11 on at

    @takolota 

     

    I want to sincerely thank you for your help. In watching the video on that link, I came across your channel and saw the "Automate Reports From External Datasource" video and it perfectly fits my needs, I seriously can't thank you enough.

     

     

  • takolota1 Profile Picture
    4,974 Moderator on at

    @JBR15 

    That’s awesome, glad I could help!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 503 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 321 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard