Calculated column or measure?
The most common question when starting with DAX: does the formula belong in a column or in a measure? The answer depends on whether you need a value per row or a number that changes with the filters in the report.
In short: a column when every row needs a value of its own that you want to group or filter by. A measure for KPIs calculated per cell from many rows. Often both work together: the column per row, the measure summarizes.
Prerequisites: Calculated columns.
Try it now
Task Create the calculated column "Unit Price" in Sales: Amount divided by Quantity, for every order.
Sales 120 rows, 7 columns
| OrderID | OrderDate | ShipDate | ProductID | RegionID | Quantity | Amount |
|---|---|---|---|---|---|---|
| 1 | 3 Oct 2026 | 6 Oct 2026 | 1 | 2 | 2 | 1798 |
| 2 | 9 Nov 2025 | 19 Nov 2025 | 2 | 3 | 5 | 1145 |
| 3 | 20 Sep 2026 | 27 Sep 2026 | 5 | 4 | 4 | 596 |
| 4 | 16 Jun 2025 | 2 Jul 2025 | 2 | 1 | 5 | 1145 |
| 5 | 26 Mar 2026 | 31 Mar 2026 | 1 | 3 | 4 | 3596 |
| 6 | 4 Dec 2025 | 10 Dec 2025 | 5 | 4 | 5 | 745 |
| 7 | 8 Jul 2025 | 26 Jul 2025 | 6 | 1 | 4 | 196 |
| 8 | 20 Feb 2025 | 1 Mar 2025 | 3 | 2 | 3 | 59.7 |
| 9 | 9 Dec 2025 | 24 Dec 2025 | 6 | 2 | 2 | 98 |
| 10 | 12 Aug 2026 | 25 Aug 2026 | 2 | 1 | 2 | 458 |
| 11 | 7 Sep 2026 | 12 Sep 2026 | 5 | 4 | 2 | 298 |
| 12 | 2 Mar 2026 | 14 Mar 2026 | 6 | 2 | 3 | 147 |
Showing the first 12 of 120 rows.
Measures: [Total Sales]
Product 6 rows, 4 columns
| ProductID | Product | Category | Price |
|---|---|---|---|
| 1 | Laptop | Hardware | 899 |
| 2 | Monitor | Hardware | 229 |
| 3 | Mouse | Accessories | 19.9 |
| 4 | Keyboard | Accessories | 39.9 |
| 5 | Office suite | Software | 149 |
| 6 | Antivirus | Software | 49 |
Region 4 rows, 2 columns
| RegionID | Region |
|---|---|
| 1 | North |
| 2 | South |
| 3 | West |
| 4 | East |
Date 730 rows, 4 columns
| Date | Year | Month | MonthName |
|---|---|---|---|
| 1 Jan 2025 | 2025 | 1 | Jan |
| 2 Jan 2025 | 2025 | 1 | Jan |
| 3 Jan 2025 | 2025 | 1 | Jan |
| 4 Jan 2025 | 2025 | 1 | Jan |
| 5 Jan 2025 | 2025 | 1 | Jan |
| 6 Jan 2025 | 2025 | 1 | Jan |
| 7 Jan 2025 | 2025 | 1 | Jan |
| 8 Jan 2025 | 2025 | 1 | Jan |
| 9 Jan 2025 | 2025 | 1 | Jan |
| 10 Jan 2025 | 2025 | 1 | Jan |
| 11 Jan 2025 | 2025 | 1 | Jan |
| 12 Jan 2025 | 2025 | 1 | Jan |
Showing the first 12 of 730 rows.
The difference
| Calculated column | Measure | |
|---|---|---|
| Calculates | once per row, at load time | per cell in the report, on every filter change |
| Context | row context: the values of the current row | filter context: every row the filters leave |
| Storage | takes space in the model | takes none, only calculation time |
| Used in | rows, axes, slicers, filters | values, cards, KPIs |
| Example | unit price per order, age group per customer | sales, order count, percent of total |
Working together
Many KPIs need both. The unit price belongs to every order, so a column. Its average per category depends on the filters, so a measure over that column. A measure with just the column's formula fails because it has no current row.
Task Find the error: the measure should show the average of the unit prices across all orders. The column Sales[Unit Price] from the previous exercise already exists. Why does the formula fail, and how does it work?
Sales 120 rows, 8 columns
| OrderID | OrderDate | ShipDate | ProductID | RegionID | Quantity | Amount | Unit Price |
|---|---|---|---|---|---|---|---|
| 1 | 3 Oct 2026 | 6 Oct 2026 | 1 | 2 | 2 | 1798 | 899 |
| 2 | 9 Nov 2025 | 19 Nov 2025 | 2 | 3 | 5 | 1145 | 229 |
| 3 | 20 Sep 2026 | 27 Sep 2026 | 5 | 4 | 4 | 596 | 149 |
| 4 | 16 Jun 2025 | 2 Jul 2025 | 2 | 1 | 5 | 1145 | 229 |
| 5 | 26 Mar 2026 | 31 Mar 2026 | 1 | 3 | 4 | 3596 | 899 |
| 6 | 4 Dec 2025 | 10 Dec 2025 | 5 | 4 | 5 | 745 | 149 |
| 7 | 8 Jul 2025 | 26 Jul 2025 | 6 | 1 | 4 | 196 | 49 |
| 8 | 20 Feb 2025 | 1 Mar 2025 | 3 | 2 | 3 | 59.7 | 19.9 |
| 9 | 9 Dec 2025 | 24 Dec 2025 | 6 | 2 | 2 | 98 | 49 |
| 10 | 12 Aug 2026 | 25 Aug 2026 | 2 | 1 | 2 | 458 | 229 |
| 11 | 7 Sep 2026 | 12 Sep 2026 | 5 | 4 | 2 | 298 | 149 |
| 12 | 2 Mar 2026 | 14 Mar 2026 | 6 | 2 | 3 | 147 | 49 |
Showing the first 12 of 120 rows.
Measures: [Total Sales]
Product 6 rows, 4 columns
| ProductID | Product | Category | Price |
|---|---|---|---|
| 1 | Laptop | Hardware | 899 |
| 2 | Monitor | Hardware | 229 |
| 3 | Mouse | Accessories | 19.9 |
| 4 | Keyboard | Accessories | 39.9 |
| 5 | Office suite | Software | 149 |
| 6 | Antivirus | Software | 49 |
Region 4 rows, 2 columns
| RegionID | Region |
|---|---|
| 1 | North |
| 2 | South |
| 3 | West |
| 4 | East |
Date 730 rows, 4 columns
| Date | Year | Month | MonthName |
|---|---|---|---|
| 1 Jan 2025 | 2025 | 1 | Jan |
| 2 Jan 2025 | 2025 | 1 | Jan |
| 3 Jan 2025 | 2025 | 1 | Jan |
| 4 Jan 2025 | 2025 | 1 | Jan |
| 5 Jan 2025 | 2025 | 1 | Jan |
| 6 Jan 2025 | 2025 | 1 | Jan |
| 7 Jan 2025 | 2025 | 1 | Jan |
| 8 Jan 2025 | 2025 | 1 | Jan |
| 9 Jan 2025 | 2025 | 1 | Jan |
| 10 Jan 2025 | 2025 | 1 | Jan |
| 11 Jan 2025 | 2025 | 1 | Jan |
| 12 Jan 2025 | 2025 | 1 | Jan |
Showing the first 12 of 730 rows.
This exercise is part of Premium.
Premium unlocks every exercise in every lesson, unlimited practice with fresh tasks and the final test with certificate.
See Premium Already Premium? Log in
The first exercise in this lesson is free.
Rules of thumb
- If the result should appear in rows, on an axis or in a slicer: column.
- If it should change when someone filters the report: measure.
- When in doubt, a measure: it does not make the model bigger.
- Columns that only use values from the same row can often be done in Power Query already.
Common mistakes
A total as a column
A column Total = SUM(Sales[Amount]) writes the same grand total into every row. It does not get smaller when the report filters. Totals belong in measures.
Not every average is the same
The average of the unit prices treats every order equally. Total sales divided by total quantity is weighted by quantity. Both are right, but for different questions.
Frequently asked questions
Can a measure use a calculated column?
Yes, like any other column, with an aggregation such as SUM or AVERAGE.
And the other way round?
A column can call a measure. The measure then calculates for every row with that row's filter (context transition). That is a topic for levels 4 and 5.