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 / SQL Insert Row - Parse...
Power Automate
Unanswered

SQL Insert Row - Parse JSON inserting only NULL rows

(0) ShareShare
ReportReport
Posted on by

Hi everyone,

 

I have build a flow to be triggered when a new Excel file is uploaded to a SharePoint folder. The flow takes a table in the Excel file and then inserts each row in a SQL table.

 

As an outline, this is what the flow looks like:

 

kdp321_1-1626684897991.png

The "Parse JSON" operator looks like:

 

kdp321_2-1626684958795.png

And the "Insert row" for SQL, where each field in the SQL table is linked to the corresponding field in the JSON:

kdp321_3-1626685082740.png

 

The problem comes when I run the flow, the JSON outputs contain the data from the Excel table, but the are not input into the SQL connector. The output of the Parse JSON, which contains data as highlighted:

kdp321_5-1626685290022.png

However in the SQL connector the output does not make sense:

kdp321_6-1626685347606.png

And in the corresponding SQL table, the flow does write into the SQL table but the values remain NULL:

 

kdp321_7-1626685412142.png

 

 

 

 

 

Categories:
I have the same question (0)
  • ScottShearer Profile Picture
    25,270 Most Valuable Professional on at

    @kdp321 

    Can you tell me why you are using the Parse JSON action rather than just referencing the Excel columns from Dynamic properties when inserting a row?

     

     

  • Community Power Platform Member Profile Picture
    on at

    Thanks @ScottShearer 

     

    The flow is triggered when a user adds a new excel file, and then the table in that new file has to be uploaded to SQL. The problem that I have is, because I'm not linking my flow to a specific file, I'm not able to link those columns in excel table to the corresponding fields in my SQL table. When I look under my dynamic properties in the SQL connector, all I see are these:

     

    kdp321_0-1626759395649.png

     

    For me to be able to do that I would need to see the names of the corresponding fields from my Excel table, right?

  • ScottShearer Profile Picture
    25,270 Most Valuable Professional on at

    @kdp321 

    Is the Excel file structure, table names, etc. the same for each file and just the name is different?

     

  • Community Power Platform Member Profile Picture
    on at

    @ScottShearer - yes. So my idea is to have the user upload an excel file which contains a preconfigured table every week. So the excel files will have different names, but the table I want to extract has the same structure every week

  • Community Power Platform Member Profile Picture
    on at

    SOLVED:

     

    What I did was place the Insert Row in SQL after the Parse JSON connector:

     

    kdp321_0-1626947053262.png

     

    And then to map the Parsed JSON to specific fields in my SQL table I used the expression - "items()?['column_names'] for each column in SQL. After the first run, the connection to my excel table was established and it's working perfectly

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 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard