Forum Discussion
Summing by Client
- 1 year ago
Hi homboy27,
Thank you for reaching out to Microsoft Fabric Community Forum.
can you try with this calculated column and let us know if you face any issues.this will pull total sales per client from Table B into Table A, but only show it once per client, on a specific row.
TotalSales_Once = VAR CurrentClient = TableA[Client] VAR CurrentLocation = TableA[Location] VAR IsFirstRow = TableA[Location] = CALCULATE( MIN(TableA[Location]), FILTER(TableA, TableA[Client] = CurrentClient) ) VAR TotalSales = CALCULATE( SUM(TableB[Sales]), FILTER(TableB, TableB[Client] = CurrentClient) ) RETURN IF(IsFirstRow, TotalSales, 0)Regards,
Chaithanya.
homboy27
Having difficulty understanding your requirement, could you show the expected outcome, you may paste the expected result in your reply.
Please see below the desired section. I am pulling the total sales from Table B into Table A. However I only want the sales for client A to be on 1 column and not on all the columns. So i would like the number that I highlighted to be 0 and not pull in $10k.
- Ashish_Mathur1 year agoSuper User
Hi,
In the first place, why do you want to do this? Why not get 5,000 and 5,000? Also, even if you want 10,000, why should it be for Location A, why not B? Would you be OK with a Power Query solution? If yes, then share data in a format that can be pasted in an MS Excel file.