Forum Discussion

keltzjd's avatar
keltzjd
Brass Contributor
Feb 04, 2022
Solved

Formula to Return a Sum Between Dates when Date Matches Column Header and Name Matches

Hello! I'm trying to build an interactive connect between two tables for the end goal of project management and deconfliction. Below are the examples of my tables:   Table 1 - Project Management Ov...
  • SergeiBaklan's avatar
    SergeiBaklan
    Feb 07, 2022

    keltzjd 

    That could be like

    =SUM(
        MMULT(
            --(Table578[[PM]:[CM5]] = Table10[@[Name]:[Name]] ),
            SEQUENCE( COLUMNS( Table578[[PM]:[CM5]] ), , 1,0) ) *
       Table578[[SUM]:[SUM]] *
       ( Table578[[Start Date]:[Start Date]] <=
          DATEVALUE(Table10[[#Headers],[2022-01-01]] )
       ) *
      ( Table578[[End Date]:[End Date]] >=
        DATEVALUE(Table10[[#Headers],[2022-01-01]] )
      )
    )

    I renamed first two columns to use DATEVALUE() in my regional format, most probably is not needed in your case.

Resources