Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Can anyone give a good reason (other than backwards compatability) for using calculated columns in DAX?
As I see it, I can create columns in Query (Which get compressed into the data model) for everything I need, rather than creating calculated columns in DAX (which may not get compressed, hence inflating the data model). For everything else there's Measures. So I'm struggling to find a use case for DAX Column Calculations, or have I missed something?
regards
Stuart
There are a number of reasons but probably primarily ease of use. There are certain things that are just easier to do in DAX rather than in "M" code. A good example of this is dealing with dates and times. For certain things it is 1 line of DAX versus multiple complex lines of M code. In addition, DAX is very Excel formula like. M is a complex, functional programming language and the Query Editor does not provide easy access to perhaps 50-60% or more of what M is capable of. And not everyone is a developer out there.
Also remember that DAX is part of SQL Server Analysis Services Tabular. So it's application goes beyond Power BI. Power BI just happens to use SSAS Tabular under the hood so DAX kind of comes along for the ride.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |