Forum Discussion

Kolumam's avatar
Kolumam
Post Prodigy
8 years ago
Solved

Retrieving a value based on another column

I have two columns, one being Solar percentage and another is a date field. I want to retreive the value of the most recent date. how do I do this ?
  • v-jiascu-msft's avatar
    8 years ago

    Hi Kolumam,

     

    You try a measure like this:

     

    Measure =
    VAR maxDate =
        CALCULATE ( MAX ( 'Table1'[Date] ), ALL ( Table1 ) )
    RETURN
        CALCULATE ( MIN ( 'Table1'[Value] ), 'Table1'[Date] = maxDate )

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

     

    Best Regards!

    Dale