4 Replies Latest reply on Jul 7, 2017 10:50 AM by Kendra Allenspach

    Return Max(Date) based on value of another measure

    Kendra Allenspach

      Hi there Tableau gurus,

       

      I am trying to return the max(date) in a data set, but based on another measure.

       

      For example, if the below is my data set, I want the Max Date where Impressions are greater than zero, so 1/1/17, as opposed to the max date in the data set which is 1/2/17.

      DateClicksImpressions
      01-01-1725
      01-02-1740

       

       

      I tried to do a formula as follows, but it is still returning the max(Date) in the data set.

       

      iif([Impressions]>0,MAX([Date]),null)

       

      I am probably missing something obvious, but as I am still fairly new to Tableau I am stumped. Any help is greatly appreciated!!

       

      Thank you!

       

      Kendra