Forum Discussion

AllanBerces's avatar
AllanBerces
Icon for Post Prodigy rankPost Prodigy
2 years ago
Solved

Max Completed Date

Hi Good Day, I need help on my table, pls refer below. i want only the maximun date of completed group category to register on my Week Column and year column, on my example only 3 group category com...
  • Anonymous's avatar
    Anonymous
    2 years ago

    Thanks for the reply from rajendraongole1 , please allow me to provide another insight: 

    Hi  AllanBerces ,

     

    Here are the steps you can follow:

    1. Create calculated column.

    Week No. =
    var _count100=COUNTX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])&&'Table'[Comp %]=100),[Comp %])
    var _count=COUNTX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])),[Comp %])
    var _alldate=MAXX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])),[Date Completed])
    return
    IF(
        _count100=_count&&'Table'[Date Completed]=_alldate,WEEKNUM(_alldate,2),BLANK())
    Year =
    var _count100=COUNTX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])&&'Table'[Comp %]=100),[Comp %])
    var _count=COUNTX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])),[Comp %])
    var _alldate=MAXX(FILTER(ALL('Table'),'Table'[Category]=EARLIER('Table'[Category])),[Date Completed])
    return
    IF(
        _count100=_count&&'Table'[Date Completed]=_alldate,YEAR(_alldate),BLANK())

    2. Result:

    As far as I can see from looking at your sample data, I found a bit of information that is a little different from what you said:

    EEE max date should be 2024.5.11

    HHH max date should be 2024.4.17

     

    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

  • AllanBerces's avatar
    AllanBerces
    2 years ago

    Hi Anonymous thank you very much work as i need.