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:
The "Parse JSON" operator looks like:
And the "Insert row" for SQL, where each field in the SQL table is linked to the corresponding field in the JSON:
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:
However in the SQL connector the output does not make sense:
And in the corresponding SQL table, the flow does write into the SQL table but the values remain NULL:
SOLVED:
What I did was place the Insert Row in SQL after the Parse JSON connector:
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
@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
Is the Excel file structure, table names, etc. the same for each file and just the name is different?
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:
For me to be able to do that I would need to see the names of the corresponding fields from my Excel table, right?
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?
Michael E. Gernaey
566
Super User 2025 Season 1
David_MA
516
Super User 2025 Season 1
stampcoin
492