Forum Discussion
Adding a start value
Good afternoon to you all.
I have a waterfall chart and I want to add a starting value through DAX. My point is to add a given bank balance (which is in another table) to a bank movement account. I created the following DAX:
2 Replies
- lbendlinSuper User
You cannot add a row to a DAX table (at least not to an existing one). You need to add that row in Power Query, or in your data source.
- AnonymousNot applicable
Hi Anonymous ,
My sample data is this.
DateAmountAccount ID
1/1/2020 50 1 5/4/2020 55 2 4/16/2020 56 3 2/1/2020 51 1 last_valueAccount ID
5 1 3 2 4 3 Then you may try this measure. The ALLEXPECT removes all context filters in the table except filters that have been applied to the specified columns.
Measure = IF ( MAX ( 'Tabela_Pagamentos'[Date] ) = CALCULATE ( MIN ( 'Tabela_Pagamentos'[Date] ), ALLEXCEPT ( Tabela_Pagamentos, Tabela_Pagamentos[Account ID] ) ), MAX ( 'Tabela_Pagamentos'[Amount] ) + MAX ( 'Table (2)'[last_value] ), MAX ( 'Tabela_Pagamentos'[Amount] ) )If this is not the result you want, please provide some sample data or detailed screenshots, remember to protect your sensitive information.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.