Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago

Measure on expanded dates

Hello, when I expand dates field in months in a matrix, I would like it to only affect Valeur 1 and not affect Valeur 2 (Only get one column of the average of Valeur 2 no matter if the dates are expanded or not). Is it possible?

 

            

 

Here is the data set

 

Thank you

 

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi  Anonymous ,

    Here are the steps you can follow:

     

    1. Create measure.

    Avg value2 =
    AVERAGEX(FILTER(ALLSELECTED('Table'),'Table'[Category]=MAX('Table'[Category])),[Value2])
    Sum Value1 =
    SUMX(
    FILTER(ALL('Table'),'Table'[Category]=MAX('Table'[Category])&&'Table'[Date]=MAX('Table'[Date])),[Value1])

    2. Result:

     

    Year:

    Month:

     

     

    Best Regards,

    Liu Yang

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

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hello Anonymous , thanks for the response but it is not what I'm looking for. I want to see the average of valeur 2 only in one column all the time. So being able to expand by month sum of Valeur 1 if needed and no matter if I expand or not, valeur 2 in one column (Acting like it is a dimension). Thank you