Forum Discussion

campelliann's avatar
campelliann
Icon for Post Patron rankPost Patron
4 years ago
Solved

New column returning always the same value on a virtual table

Hi there, I have this table with project data, where each project lives on one row. I have several columns for each row, amongs them the beginning and ending date.   Table Sample Project ID ...
  • Greg_Deckler's avatar
    Greg_Deckler
    4 years ago

    campelliann I believe you want something like this:

    Table =
      VAR __Project = SELECTEDVALUE('Triskall Complete'[Process])
      VAR __Table = 
        ADDCOLUMNS(
          FILTER('Triskall Complete',[Process] = __Project),
          "__Days",([End Date] - [Start Date]) + 0
        )
    RETURN
      __Table