Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
I have a Table 1 using this I need to create a Table 2 as shown in the image below. I would appreciate any help with the logic on this to be done either using DAX or maybe in Tableau. Thank you.
Note: If a transaction id has a class 'SP' then for that transaction id replace the class 'WSP' with 'SP' and then get the sum for that transaction id.
Solved! Go to Solution.
This Column for New Revenue
New Revenue = CALCULATE ( SUM ( TableName[Revenue] ), ALLEXCEPT ( TableName, TableName[Transaction ID] ) )
HI @ketan10
Try this Calculated Column
New Class = IF ( CALCULATE ( COUNTROWS ( TableName ), FILTER ( ALLEXCEPT ( TableName, TableName[Transaction ID] ), TableName[Class] = "SP" ) ) >= 1, "SP", TableName[Class] )
This Column for New Revenue
New Revenue = CALCULATE ( SUM ( TableName[Revenue] ), ALLEXCEPT ( TableName, TableName[Transaction ID] ) )