Forum Discussion

BTLYBSCT's avatar
BTLYBSCT
Regular Visitor
7 years ago
Solved

DAX - Getting a value based off the earliest and latest dates

Hi All,   I have a report that produces once a month and with every report I receive the same data set with a few new rows.   I have created a field for Month/Year so I can keep track of the incr...
  • BTLYBSCT's avatar
    BTLYBSCT
    7 years ago

    Hi All,

     

    I have been able to solve this through sing the formula below.

     

    ED Contract Status = 
    CALCULATE(MAX('CCO Impairment_Asset_View'[Contract Status]),FILTER('CCO Impairment_Asset_View','CCO Impairment_Asset_View'[Contract No] = EARLIER('CCO Impairment_Asset_View'[Contract No]) && 'CCO Impairment_Asset_View'[Month/Year] = earlier('CCO Impairment_Asset_View'[Earliest Date])))

    Hopefully this will be able to help someone in the future.