3 Replies Latest reply on Sep 22, 2019 9:54 AM by Hari Ankem

    How to look for duplicates across dates

    Rakesh B

      In the below data, is there a way in Tableau to get only one row when I have same ID's and Systems but different dates (usually within three days). The desired result is one row for the first three (any one of them will do).

       

        

      Date         IDSystem
      8/15/201822Vacuum
      8/14/201822Vacuum
      8/16/201822Vacuum
      8/31/201823Other
      8/21/201824Blower
        • 1. Re: How to look for duplicates across dates
          Hari Ankem

          Create this calculated field and add to the filters:

           

          {FIXED [ID], [System]: MIN([Date])} = [Date]

          • 2. Re: How to look for duplicates across dates
            Rakesh B

            Hi Hari, thank you for your response.

             

            One key aspect that I forgot to mention is that I don't want to look in the entire date dimension. I just want to look in the +/- 3 days from each row date. I have used FIXED LOD but it gives me the minimum date from the entire date field. This is not what I'm looking for as I have thousands of rows with dates from past few years but with same ID and System. Is this still possible?

             

            I apologize for not stating my requirement clearly in the question. This is my first question in this forum and I am learning.

            • 3. Re: How to look for duplicates across dates
              Hari Ankem

              I will suggest that you do not look at the data like that. If you have all the dates in a month, looking at +/- days from each date does not get you separate/independent groups of data. So, I would rather suggest that you look at the data at a weekly level.

               

              {FIXED [ID], [System]: MIN(DATETRUNC("week",[Date]))} = DATETRUNC("week",[Date])