Forum Discussion
Measure question
- 6 years ago
Always fun to create a measure here and there 🙂 Had some trouble in the beginning because I didn't do the formatting correcly (decimal numbers) but that was because of the locale settings of my Excel and PBI 😉
Anyway, here is the Measure you can use for it:
Measure = IF(HASONEVALUE('Table'[Order type]), VAR orderType = SELECTEDVALUE('Table'[Order type]) RETURN CALCULATE(SUM('Table'[Mandate amount]), FILTER(ALL('Table'), 'Table'[Order type] = orderType && ISBLANK('Table'[Invoiced amount]) = TRUE)))Creating a Table visual with the column 'Order type' and the measure results in this:
Note that this measure only returns a result in a context of a single Order Type, and hence the total line is empty (as that evaluates the measure for the whole data set, so with two order types present). If you don't want that, you can simplify the measure like to this:
Measure = CALCULATE(SUM('Table'[Mandate amount]), FILTER('Table', ISBLANK('Table'[Invoiced amount]) = TRUE))Resulting in the following table visual:
Let me know if this works! 🙂
Kind regards
Djerro123
-------------------------------
If this answered your question, please mark it as the Solution. This also helps others to find what they are looking for.
Keep those thumbs up coming! 🙂
Hi Anonymous
- Anonymous6 years agoNot applicable
Hi Maggy,
Sorry for the delay. This friday, I have time to check the proposed solution (and accept it if it works).
Cheers, Sander