Forum Discussion

phoisan's avatar
phoisan
Helper I
6 years ago
Solved

Create a measure which will return a specific column value based on other measure Power BI Desktop

Hi!   I wanted to create a measure which will return a specific column value based on other measure TimeInHours is a column TCO is a measure I manage to find the min TCO value = 291.04. I wa...
  • v-xicai's avatar
    6 years ago

    Hi phoisan ,

     

    You may create measure like DAX below.

     

    Measure 1 =
    
    var _Table=SUMMARIZE(TimeFrame, TimeFrame[TimeInHours], "tcd" , [TCO])
    
    Var MinTcd=MINX(_Table, [tcd])
    
    return
    
    CALCULATE(FIRSTNONBLANK(TimeFrame[TimeInHours], 1),FILTER(_Table, [tcd]=MinTcd))

     

    Best Regards,

    Amy 

     

    Community Support Team _ Amy

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