Forum Discussion

SUMESHKUMAR22's avatar
SUMESHKUMAR22
Icon for Helper IV rankHelper IV
1 year ago
Solved

Measure not filtering as per time Calculation

Hi Community,

In the attached pbix file, Im facing issue with Problem -1 in atached pbix.

Issue : Im trying to use colesce function in the base measure 'vall' but due to that the date filter context is getting removed and showing data for all dates. But when i dont use colesece it works fine. 


Thanks in advance! 

  • Hakuna_matata's avatar
    Hakuna_matata
    1 year ago

    Hi SUMESHKUMAR22 ,
    Try this measure

    vall =
    CALCULATE(
        SUM('Sample'[VALUE]),
        ALLSELECTED('DIM Date'[Date])
    )

    If this solved your problem, please accept it as a solution!! ^_^

     

5 Replies

  • Hi SUMESHKUMAR22 ,
    I may suggest updating the "val" to below measure

    val =
    CALCULATE(
        COALESCE(SUM('Sample'[VALUE]), 0),
        ALLSELECTED('DIM Date'[Date])
    )
    Hope it help!
    If this solved your problem, please accept it as a solution!!
    • SUMESHKUMAR22's avatar
      SUMESHKUMAR22
      Icon for Helper IV rankHelper IV

      Hi Hakuna_matata ,

      It didn't work still even after adjusting the base measure 'vall' .

      Any other possibilities to fix this ?


      Thanks in advance!

      • Hakuna_matata's avatar
        Hakuna_matata
        Icon for Resolver I rankResolver I

        Hi SUMESHKUMAR22 ,
        Try this measure

        vall =
        CALCULATE(
            SUM('Sample'[VALUE]),
            ALLSELECTED('DIM Date'[Date])
        )

        If this solved your problem, please accept it as a solution!! ^_^