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.
My input dataset is as follows:
Cash | 20
|
CashX | 0.90 |
Interest | 2.6 |
Loan | 100 |
When I'm reporting on the above data, Cash column must be calculated as value(Cash+CashX).
I'm trying to use a measure to do this, but I cant add botht he numbers.
Any help is greatly appreciated.
ara
Solved! Go to Solution.
@Anonymous , Create a new column
New group = switch( True(),[column] in {"Cash","CashX"},"Cash",
[column])
or try binning/
SEGMENTATION
https://radacad.com/grouping-and-binning-step-towards-better-data-visualization
https://www.daxpatterns.com/dynamic-segmentation/
https://www.daxpatterns.com/static-segmentation/
https://www.poweredsolutions.co/2020/01/11/dax-vs-power-query-static-segmentation-in-power-bi-dax-power-query/
Hi,
Write this calculated column formula and rename the column to Revised text
=if(ISNUMBER(SEARCH("Cash",Data[Text],1,BLANK())),"Cash",Data[Text])
To your visual, drag this revised text column and write this meaure
Total = SUM(Data[Amount])
Hope this helps.
Hi,
Try this measure
=calculate(sum(data[amount]),data[text]="Cash"||data[text]="Cashx")
Hope this helps.
I do not understand your comment at all.
Sorry @Ashish_Mathur , I should have been more specific.
After adding the formula you had mentioned, all the rows get the sum of Cash and CashX
Cash | 20.90 |
CashX | 20.90 |
Interest | 20.90 |
Loan | 20.90 |
Hope this makes sense.
Hi,
Write this calculated column formula and rename the column to Revised text
=if(ISNUMBER(SEARCH("Cash",Data[Text],1,BLANK())),"Cash",Data[Text])
To your visual, drag this revised text column and write this meaure
Total = SUM(Data[Amount])
Hope this helps.
@Anonymous , Create a new column
New group = switch( True(),[column] in {"Cash","CashX"},"Cash",
[column])
or try binning/
SEGMENTATION
https://radacad.com/grouping-and-binning-step-towards-better-data-visualization
https://www.daxpatterns.com/dynamic-segmentation/
https://www.daxpatterns.com/static-segmentation/
https://www.poweredsolutions.co/2020/01/11/dax-vs-power-query-static-segmentation-in-power-bi-dax-power-query/
Thanks @amitchandak
Using the switch statement, I now have 2 Cash rows, how do Iadd the values of Cash and CashX?
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
99 | |
83 | |
70 | |
60 |
User | Count |
---|---|
150 | |
115 | |
104 | |
89 | |
65 |