Forum Discussion

JaakLab's avatar
JaakLab
New Member
7 years ago
Solved

Closing balance slicer problem

Hi Everyone

I want to show the closing balance per month and year from a table that looks like below:

 

SiteDescriptionDateBalance
AReceivable A31-Jan-19100
AReceivable A28-Feb-1990
AReceivable B31-Jan-1950
AReceivable B28-Feb-1950
BReceivable A31-Jan-1970
BReceivable A28-Feb-1980
BReceivable B31-Jan-19200
BReceivable B28-Feb-19210
CReceivable A31-Jan-1960
CReceivable A28-Feb-1960
CReceivable B31-Jan-19150
CReceivable B28-Feb-19140

 

To calculate the closing balance I use this measure:

 

ClosingBalancePerMonth =
VAR LASTBALANCEDATE = MAX ( 'table'[Date] )
RETURN
CALCULATE (
SUM ( 'table'[Balance] ),
'table'[Date] = LASTBALANCEDATE
)
 
My problem is that when I add a slicer, it works perfectly for Site A, but Site B and C shows no data on the visual. I think it is because the dates are duplicated, so my measure only picks the first date which belongs to Site A, but I don't know. Help please.

4 Replies

  • v-xicai's avatar
    v-xicai
    Icon for Community Support rankCommunity Support

    Hi JaakLab 

     

    Based on my test, [Site] slicer not only works perfectly for Site A, but also for the Site B and C on the visual.

     

     

     

     

     

     

    For example, when select Site B or C in slicer, return the result showing picture below.

     

     

     

     

     

     

     

     

     

     

    You can check if there are other limitations on the visual showing the measure.

     

    Best Regards,

    Amy

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

  • Thank you so much Amy and Ashish for the help. My error was that my 'Date' linked to my Calendar table and not to the date in the table containing the balances.