Follow order O01-02 into the sales measure
At UGX 12,000 per crate, which quantity belongs in delivered sales?
- Requested
8 crates - Delivered
6 crates - Unfilled
2 crates
Check your reading
Six delivered crates give UGX 72,000 in sales. The two unfilled crates explain the gap between the requested and delivered quantities.
Open the case files, data dictionary and portfolio challenge
Power BI Tutorial for Beginners (Step-by-Step in 30 Minutes)
Start at 5:04 for source selection. Follow the handoff from getting data to the first Power Query transformation at 9:10.
- Try it
- Connect Power BI Desktop to orders.csv using Text/CSV. Inspect one order in Transform Data and identify which fields describe units and which describe prices.
- Check your work
- A row with several delivered units still represents one order. Use delivered units multiplied by the unit price when you calculate its sales value.
Kampala wants to know whether a shortfall came from lower sales volume or incomplete delivery. Start by preserving the difference between ordered and delivered units. In this training extract each order contains one product at one price. O01-02 requests eight crates at UGX 12,000 and receives six. The delivered sales amount is UGX 72,000. The two missing units are a service gap. Counting the entire order as sales would hide that gap.
- Download orders.csv, products.csv, targets.csv and intake.csv to a local folder. Keep challenge.csv aside until the final project. In Power BI Desktop choose Get data → Text/CSV → orders.csv → Transform Data. Rename the query Orders.
- In Power Query select the identifier and branch columns and set the type to Text. Set order_date to Date. Set all four quantity/price fields and days_to_deliver to Whole Number. If a date errors, use Change Type → Using Locale and inspect year, month and day on O01-02.
- Use New Source → Text/CSV to bring in Products and Targets. Name them exactly as shown. Set Products fields to Text, Targets[branch] to Text, Targets[month] to Date and Targets[target_ugx] to Whole Number. Keep the original source files intact.
- Turn on View → Column quality, distribution and profile. Switch profiling to the entire dataset. Check Orders contains 96 rows, with 96 different order IDs. Products contains four different IDs. Check one month and branch per target row. Close & Apply and save a PBIX.
An empty delivery duration for O01-07 has a business meaning. Its delivered quantity is zero. Keeping the missing duration separate lets a report describe delivery time for observed deliveries while still counting the order in unmet demand.