2 Replies Latest reply on Jun 23, 2016 1:26 AM by Aym cham

    compare multiple rows and return value

    Aym cham

      Hi all,

       

      I have this:

       

      rowDateNameValue
      11/01/2016test11
      21/01/2016test11
      32/01/2016test15
      42/01/2016test15
      51/01/2016test220
      62/01/2016test225
      72/01/2016test225
      81/01/2016test310
      92/01/2016test315

       

      I want to compare this table row by row.

       

      first case:

      if date of row 1 = date of row2 and name of row 1 = name of row 2 then return average value

       

      second case:

      if date of row 1 != date of row2 or name of row 1 != name of row 2 then return sum value

       

      in this case, I would like to print this, in tableau:

       

      NameValue
      test16
      test245
      test325

       

      How can i do this please?

       

      Thanks in advance

       

      Aym