8 Replies Latest reply: Mar 13, 2014 5:45 PM by Michele Petersen RSS

    How to get days and records between events?

      I need to get number of days between two events and the number ofrecords between two events in Qlikview. The orginal data is as follow. I need to know the number of days between surgery infections and the number of records between infections. The summary table is attached to the data table. Is there any way to do it in Qlikview?

       

      Thanks

       

       

      PatientIDSurgeryDateInfection
      110/21/2012Yes
      210/22/2012No
      310/23/2012No
      410/24/2012No
      510/25/2012No
      610/26/2012No
      710/27/2012No
      810/28/2012No
      910/29/2012No
      1010/30/2012No
      1110/31/2012No
      1211/1/2012No
      1311/2/2012Yes
      1411/3/2012No
      1511/4/2012No
      1611/5/2012No
      1711/6/2012No
      1811/7/2012No
      1911/8/2012No
      2011/9/2012No
      2111/10/2012No
      2211/11/2012No
      2311/12/2012Yes
      2411/13/2012No
      2511/14/2012No
      2611/15/2012No
      2711/16/2012No
      2811/17/2012No
      2911/18/2012No
      3011/19/2012No
      3111/20/2012No
      3211/21/2012No
      3311/22/2012No
      3411/23/2012YES
      3511/24/2012No
      3611/25/2012No
      3711/26/2012No

       

      PatientIDSurgeryDateInfectionNumber of days between surgeriesNo. of surgeries between infection
      110/21/2012Yes
      1311/2/2012Yes
      2311/12/2012Yes
      3411/23/2012YES