Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
pavlecoric
Regular Visitor

X-aggregator function vs calculated column

I've been doing my best to learn Dax via the BiAtMicrosoft tutorials and I've got a question about calculated columns and measures. From what I understand calculated columns are best suited for slicer/ filtering purposes and measures aggregate on the tabular level. What I'd like to have clarified is when to use a calculated column and when to use an x-aggregator function in a measure. From my understanding, a calculated column and an x aggregator function both compute some value on a row by row level. Is there more to it? 

1 ACCEPTED SOLUTION
vega
Resolver III
Resolver III

Well, some information you should keep in mind, a calculated column is stored in memory and is computed once. A measure with an aggregator function (or any measure) is not stored in memory and is calculated whenever it is used. It will be up to you to balance when to use one over the other. If the value is used many times, it may be better to use a calculated column, since it is computed once and the value is always there. If the value is used occasionally, it is best to use a measure since it does not take up space in memory (which is beneficial when using a very large set of data).

View solution in original post

1 REPLY 1
vega
Resolver III
Resolver III

Well, some information you should keep in mind, a calculated column is stored in memory and is computed once. A measure with an aggregator function (or any measure) is not stored in memory and is calculated whenever it is used. It will be up to you to balance when to use one over the other. If the value is used many times, it may be better to use a calculated column, since it is computed once and the value is always there. If the value is used occasionally, it is best to use a measure since it does not take up space in memory (which is beneficial when using a very large set of data).

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.