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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
somnath6309
Helper I
Helper I

|| ABC Analysis ||

Hi,

Pls vide the following pic:

ABC Analysis.png

MarginRT is a calculated column in the product table. If we consider the first four lines in the product table ( highlighted in orange), the code of MarginRT (Margin Running Total ) may evaluates like following :


1 Margin RT =
2 VAR CurrentTotalMargins = 'Product'[TotalMargin]   ==>> 51,459.16 (the fourth row of TotalMargin Column)
3 RETURN
4 SUMX(
5 FILTER( 'Product',
6 'Product'[TotalMargin] >= CurrentTotalMargin), ==>>here we tend to think that the total of first four rows i.e. 2,38,353.72 > = 51,459.16 ( the orange highlighted area in product table )

 

In row number 4 of the Product table, i.e. "A Datam SLR Camera", there happen four iterations caused by Filter function. At row number 4, we get four figures : 81856, 53464, 51574, 51459 and the total of the same comes to 238353 which is the result of the iteration caused by Filter.
Next, the comparison happens : 2,38,353.72 > = 51,459.16 and SUMX conducts the summation of the four aforesaid figures and returns : 238353.72 .

Pls let me know whether my understanding is correct or not.
Regards,
Somnath

1 ACCEPTED SOLUTION
ajaybabuinturi
Resident Rockstar
Resident Rockstar

Hi @somnath6309,

Yes, your understanding of how that MarginRT DAX calculated column works is absolutely correct and you’ve described the row-by-row evaluation behavior quite accurately.

Thanks,
If you found this solution helpful, please consider giving it a Like👍 and marking it as Accepted Solution✔. This helps improve visibility for others who may be encountering/facing same questions/issues.

View solution in original post

2 REPLIES 2
ajaybabuinturi
Resident Rockstar
Resident Rockstar

Hi @somnath6309,

Yes, your understanding of how that MarginRT DAX calculated column works is absolutely correct and you’ve described the row-by-row evaluation behavior quite accurately.

Thanks,
If you found this solution helpful, please consider giving it a Like👍 and marking it as Accepted Solution✔. This helps improve visibility for others who may be encountering/facing same questions/issues.

GeraldGEmerick
Super User
Super User

@somnath6309 Something seems very off about that formula. First, that is not typically how you would write a running total. A running total typically needs something like an Index or Date to define "earlier" and "later". But, yes, the formula is going to create a running total of all rows whose TotalMargin is larger than the TotalMargin of the current line. To what end that is important, I am not certain.

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.