Forum Discussion
Yrstruly2021
2 years agoHelper V
Using Variables to display Total/Sum
I am using the dax below to display figures from a table: Measure =
VAR NegativeItems = {
"Profit before Brambles allocations Total",
"Share-based payments expense",
"Debtor movements"...
Anonymous
2 years agoNot applicable
Hi Yrstruly2021 ,
Based on the description, please try the following dax formula:
IntercoCashFlows =
VAR NegativeItems = {
"Interco interest and guarantee fees",
"Interco royalties",
"Statutory reallocations",
"Interco dividends Total",
"Change in interco balances",
"Change in interco recharge clearing",
"Interco cash flow adjustments"
}
VAR PositiveItems = {
"Internal restructuring",
"FX on interco debt",
"Interco capital issued",
"Interco capital returned",
"Cash balances transfer on merging entities",
"Cashflow budget flex adjustment"
}
VAR NegativeSum =
ABS(SUMX(
FILTER(
'ZTBR',
'ZTBR'[Roll_Up_Function] IN NegativeItems || 'ZTBR'[Classification] IN NegativeItems
),
'ZTBR'[Amount in USD]
)
)
VAR PositiveSum =
SUMX(
FILTER(
'ZTBR',
'ZTBR'[Roll_Up_Function] IN PositiveItems || 'ZTBR'[Classification] IN PositiveItems
),
'ZTBR'[Amount in USD]
)
RETURN
NegativeSum + PositiveSum
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Yrstruly20212 years agoHelper V
Where is the variable to bring it into my main code?