Forum Discussion

antoniopgouveia's avatar
antoniopgouveia
Frequent Visitor
8 years ago
Solved

Find next value by date

Hi all,   I have created an index for a table of opportunities which have an associated date for each entry. I have, then, concatenated the index with the dates (format: YYmmdd) to create my IndexD...
  • Zubair_Muhammad's avatar
    8 years ago

    antoniopgouveia

     

    Try with following

     

    Column =
    VAR temp =
        TOPN (
            1,
            FILTER ( Table1, [Index] = EARLIER ( [Index] ) && [Date] > EARLIER ( [Date] ) ),
            [Date], ASC
        )
    VAR result =
        MINX ( temp, [IndexDate] )
    RETURN
        IF ( ISBLANK ( result ), [IndexDate], result )