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

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.

Reply
BeeleJa
Helper I
Helper I

SUMIF to DAX single value to repeat

Hi All,

 

Can anybody assist with translating this Excel fomula to DAX.

 

=SUMIFS(S:S;K:K;K108;M:M;"INT_REPAIR";P:P;"Service")

 

The result I am looking for is a Column where the amount listed at ProductGroupID ' Service' is shown for the related CASEID and CASEID_TYPEID

Please note the CASEID_TYPEID has also different values in the table

 

Table in Power BI

BeeleJa_0-1603263007764.png

 

Result I am looking for in Excel format

BeeleJa_1-1603263527728.png

 

 

 

 

1 ACCEPTED SOLUTION

amitchandak - many thanks for the provided solution, it is providing the result I was looking for

Rgds

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@BeeleJa ,Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Hi amitchandak, Is below sufficient?

 For additional understanding - I want to either have the P_AMOUNT applied when for ProductGroupIS Service is is above zero, else I want the separate P_AMOUNTS to be applied and my intention is to use the result I am now lokking for in a further IF - THEN comparison 

 

CASEIDCASEID_TYPEIDPRODUCTGROUPIDP_AMOUNTSumIf result
W00034470101INT_REPAIRService412.91412.91
W00034470101INT_REPAIREPN 412.91
W00034470101INT_REPAIRParts APU0.15412.91
W00034470101INT_REPAIRParts APU0.15412.91
W00034470102INT_REPAIRParts APU4223.917550
W00034470102INT_REPAIRParts APU151.222550
W00034470102INT_REPAIRService5050
W00034470102INT_REPAIRParts APU26.977550
W00034470102INT_REPAIRParts APU25853.8550
W00034470102INT_REPAIRParts APU 50
W00034470103INT_REPAIRParts APU1694.385352
W00034470103INT_REPAIRParts APU151.2225352
W00034470103INT_REPAIRService352352
W00034470103INT_REPAIRParts APU724.5975352
W00034470103INT_REPAIRParts APU26.9775352
W00034470103INT_REPAIRParts APU45917.025352
W00034470103INT_REPAIRParts APU11.26352
W00034470104INT_REPAIRService9362456.49
W00034470104INT_REPAIRService1520.492456.49
W00034470105INT_REPAIRService651.64651.64
W00034470106INT_REPAIRService 0
W00034470108INT_REPAIRService162.91162.91
W00034470109INT_REPAIRParts APU109.1475155
W00034470109INT_REPAIRService155155
W00034470109INT_REPAIRParts APU3965.8575155
W00034470109INT_REPAIRParts APU0.06155
W00034470109INT_REPAIRParts APU0.32155

@BeeleJa , create a new column

sumx(filter(Table, [CASEID] =earlier([CASEID]) && [PRODUCTGROUPID] = "Service"),[P_AMOUNT])+0

amitchandak - many thanks for the provided solution, it is providing the result I was looking for

Rgds

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.