Create the order without a status
In the Actions pane, search for
Read from CSVand double-click Read from CSV file. In File path, select the file-picker icon and browse toOrder.csvon your desktop. The full path, such asC:\Users\<username>\Desktop\Order.csv, is filled in for you. Expand Advanced and switch on First line contains column names. Rename the produced variable tofOrdersCSVand select Save.
Tip
💡 Tip: Reading the file first means a missing or broken file stops the flow before anything is written to Dataverse.
Add a Get current date and time action (under Date time), producing
CurrentDateTime. The order should carry the date it was imported.Add an Add a new row to selected environment action (under Microsoft Dataverse).
🔧 Setup check: If you completed Module 2 with this account, a Dataverse connection already exists, and the action opens straight to its parameters. If you're asked to Sign in instead, sign in with your lab account (the same one from Module 2) keep Authentication Type as Oauth, and select Create. If sign-in fails inside Power Automate for desktop, create the connection from the portal instead: https://make.powerautomate.com > Connections > New connection > Microsoft Dataverse, then reopen the action.
Select your Environment, and in Table name select Orders. Wait for the columns to load, expand Advanced, and configure the fields below.
What you're building here is the automated version of what you did by hand in Module 2's test: create an order, fill in its details and line items, and save it with the status New. It was that save that fired the approval flow. This action is the "create an order and fill in its details" part; the role of the save is played by the status update in Step 7.
These are the order header values. The CSV supplies only the line items, one product row each. For simplicity, this lab sets the header values as fixed entries here; in a real import, they would come from your file as well, read the same way the line items are:
- Order Status: leave empty
- Order Date:
%CurrentDateTime% - Payment Type:
Credit Card - Ship City:
London - Ship Country/Region:
United Kingdom - Notes:
Imported from legacy order file by desktop flow.
These are the fields from Module 2's approval email displays — filling them here means the approvals for imported orders arrive complete, not blank.
Important
⚠️ Important: leave Order Status empty. The status is set at the very end of the flow, after the line items exist — that update is what triggers the approval flow, and by then the order's full value is in place for it to calculate.
Rename the produced variable to
fResponseand select Save.Add a Convert JSON to custom object action (under Variables). In JSON, enter:
%fResponse%Rename the produced variable to
fObjectand select Save.Add a Set variable action. Name the variable
fOrderId, and in Value, enter:%fObject['nwind_ordersid']%This is the created order's unique identifier: the same value used in Module 2 to link the invoice to its order.
Select the save icon in the designer toolbar to save the flow.




