Skip to content
VirtualLP Virtual Learning Platform

Industry Practical: Finance Actuals, Budgets, Unpivot and Variance

8 min read Topic 36 of 38 2 hands-on labs

Understand it in simple language

The finance case has two years of monthly data, three departments and six accounts: 432 actual rows, 432 budget rows, a 36-row wide-format budget, and Account/Department dimensions. Every actual and budget row has month-department-account grain. Values are positive activity amounts: the combined actual total includes both revenue and expense accounts and is not profit.

Keep Actuals and Budgets as separate facts with shared dimensions. Joining facts by AccountID alone repeats months and departments. Raw variance is Actual minus Budget. Positive variance is usually favorable for revenue and unfavorable for expenses; agree this convention before presenting colors.

Do it step by step

  1. Download finance.zip. Import Actuals.csv, Budgets.csv, Accounts.csv and Departments.csv into Desktop, preserving query names Actuals, Budgets, Accounts and Departments. Use the retail Calendar.csv or create a complete 2024–2025 calendar.
  2. Set MonthStart to Date and amounts to Fixed Decimal. Check that the composite MonthStart + Department + AccountID key is unique in each fact. In Power Query Group By these three fields and Count Rows; every count should be one.
  3. Relate Calendar[Date] (1) to each MonthStart (), Accounts[AccountID] (1) to each fact's AccountID (), and Departments[Department] (1) to each fact's Department (*). Use Single filters from dimensions to facts. Do not create a direct relationship between Actuals and Budgets.
  4. In a separate query import Budgets_Wide.csv. Select Year, Department and AccountID > Transform > Unpivot Other Columns. Rename Attribute to MonthCode and Value to BudgetAmount. Add MonthNo with Number.FromText(Text.AfterDelimiter([MonthCode], "M")), then MonthStart with #date([Year], [MonthNo], 1) after typing Year and MonthNo as whole numbers. Expect 432 rows. Compare this with Budgets; use one version in the model to avoid double counting.
  5. Create measures separately:
Actual = SUM(Actuals[ActualAmount])
Budget = SUM(Budgets[BudgetAmount])
Variance = [Actual] - [Budget]
Variance % = DIVIDE([Variance], [Budget])
Favourable Variance = SUMX(Accounts, IF(Accounts[Type] = "Revenue", [Variance], -[Variance]))
  1. Filter Calendar Year to 2025. Build a matrix with Accounts[AccountName] and Departments[Department], showing Actual, Budget, Variance and Variance %. Add a monthly comparison. Test favorable/unfavorable labels using account type, not only the sign of raw variance.
  2. Complete the linked industry model, unpivot, variance and department-detail labs. The browser model action validates the shared Account key; complete Date and Department relationships separately in Desktop.
  3. Verify the combined activity totals, then reconcile revenue and each expense account separately. Export a grouped table and compare it with a manual account-month subset. Record assumptions, owner and period-close rules.

Check your result

For 2025, combined actual activity is 44,287,570, combined budget activity is 43,200,000, and raw variance is 1,087,570. These combined values are reconciliation checks, not a profit calculation. Wide-to-long reshaping must return 432 unique month-department-account rows. The department report must have three groups.

If something goes wrong

If the total multiplies after a join, inspect incompatible grain and duplicate keys. If a budget appears on every transaction line, use shared dimensions instead of copying budget onto each event. If favorable colors are misleading, check Revenue versus Expense classification. A blank/zero budget should not produce an uncontrolled percentage error.

Practice data and learning method

Industry practice collection: downloadable retail, finance, HR and operations datasets, dictionaries, full walkthroughs and answer sheets. The cases contain multiple years, multiple related tables, deliberate data defects and known-answer checks. Progress from the small foundation files below to these cases; do not reuse the foundation totals for the larger datasets.

Download Sales.csv, Products.csv, and the dataset guide. These files contain synthetic training data, not real customers. Use the Power BI virtual labs for guided browser practice. Each lab states its supported operations. Then repeat the procedure above in the actual Microsoft tools and save evidence of your result. Try another filter or an intentionally incorrect setting and explain what changed before moving on.

Guided practicals for this topic

Virtual lab · Microsoft Power BI · 35 min

Model actuals and budgets at compatible grain

Hands-on finance case: load the downloadable CSV tables, perform the actions, inspect the full-data result and reconcile it. Includes a paired Desktop procedure.

Open lab

Virtual lab · Microsoft Power BI · 35 min

Calculate actual versus budget variance

Hands-on finance case: load the downloadable CSV tables, perform the actions, inspect the full-data result and reconcile it. Includes a paired Desktop procedure.

Open lab

Continue learning from Microsoft

Power BI documentation · DAX reference · Power Query M reference · Power BI analyst skills map. Features, licensing, menus and availability can change; check the relevant official page for your environment.

Practise this topic

Hands-on virtual labs

Apply what you just read in a realistic, guided simulation. Free with a verified account.

Create a free account to track your progress and unlock virtual labs.