9 Replies Latest reply: Jun 24, 2009 9:30 PM by elattuca RSS

    Calculated duration time

    elattuca

      Hi all,

      I have a problem with calculated a duration time ( hh mm ss ) for every events occours for each diplay name name : I have one field that contains a date (from data time) and I would like to have a duration time between the change from a result of events and another for each diplay name.

      How I can filter in field explanation the part about memory and CPU, for example, ho have the percentage of used and avaible ?

      In attach the access file and a qlik file test .

      Can you help me please.. it's very urgent for me calculated this value today.

       

      Thanks,

      Elisabetta

        • Calculated duration time
          elattuca

          in attach the qlickview file

            • Calculated duration time
              elattuca

              Help me please ....!!!

                • Calculated duration time
                  elattuca

                  Hi oleg,

                  my problem is calculated the duration time from an event to an other referred a display name server. I hav only a start time period but I don't have a totime period. So the only mode to calculated the duration time is the difference from the start time of an event to a start time of another event referred to the same display name server.

                  The source file is an mdb file , that you will find in my post ..

                  Can you help me please .. I must compile my qlik file today !

                  Thanks ....

                    • Calculated duration time
                      Oleg Troyansky

                      Elizabetta,

                      reload your table "Events", sorted by CheckID and Date (descending), and use functions previous() and peek() to get the Date/Time from the previous record (sorted descending, it would be your next event). Decide how you want to calculate the duration for the last event. In the following example, I assign 0 to the very last event.

                      Try something like this:

                       

                       


                      Events1:
                      load
                      *,
                      if( previous(CheckID) <> CheckID, 0, peek(FromDate) - FromDate) as EventDuration
                      resident Events
                      ORDER BY
                      CheckID,
                      FromDate DESC
                      ;
                      drop table Events;


                       

                        • Calculated duration time
                          elattuca

                          Hi Oleg,

                          the script does not run as well ...... there is a message about the virtual memory and it's impossibile reload the data.

                          SOS

                            • Calculated duration time
                              elattuca

                              Hi Oleg,

                              I' don't receive any updates about my qyestion ...... I have aproblem with calculated the difference about the first value to compared with my first TimeString value... How I can modify the script as well as !!????

                               

                              Thanks thanks -----

                               

                              Elisabetta

                                • Calculated duration time
                                  elattuca

                                   

                                   

                                  Hi All,

                                  please help me to calculate the different (hh mm ss) from orario_pre and TimeString as is :

                                   

                                  orario_pre

                                   

                                   

                                   

                                  precedente

                                   

                                   

                                   

                                  TimeString

                                   

                                   

                                   

                                  EventDuration

                                   

                                   

                                   

                                  31-12-2008 23:10:29

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 22:16:46

                                   

                                   

                                   

                                  31-12-2008 22:16:46

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 22:14:51

                                   

                                   

                                   

                                   

                                  31-12-2008 22:14:51

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 22:03:35

                                   

                                   

                                   

                                   

                                  31-12-2008 22:03:35

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 21:55:03

                                   

                                   

                                   

                                   

                                  31-12-2008 21:55:03

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 21:48:44

                                   

                                   

                                   

                                   

                                  31-12-2008 21:48:44

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 21:40:13

                                   

                                   

                                   

                                   

                                  31-12-2008 21:40:13

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 21:27:32

                                   

                                   

                                   

                                   

                                  31-12-2008 21:27:32

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 21:02:07

                                   

                                   

                                   

                                   

                                  31-12-2008 21:02:07

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 19:40:32

                                   

                                   

                                   

                                   

                                  31-12-2008 19:40:32

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 17:58:48

                                   

                                   

                                   

                                   

                                  31-12-2008 17:58:48

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 17:44:23

                                   

                                   

                                   

                                   

                                  31-12-2008 17:44:23

                                   

                                   

                                   

                                  0

                                   

                                   

                                   

                                  31-12-2008 17:42:01

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   

                                   



                                   

                                  Thanks,
                                  Elisazabetta

                                  • Calculated duration time
                                    elattuca

                                     

                                     

                                    Hi All,

                                    please help me to calculate the different (hh mm ss) from orario_pre and TimeString as is :

                                     

                                    orario_pre

                                     

                                     

                                     

                                    precedente

                                     

                                     

                                     

                                    TimeString

                                     

                                     

                                     

                                    EventDuration

                                     

                                     

                                     

                                    31-12-2008 23:10:29

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 22:16:46

                                     

                                     

                                     

                                    31-12-2008 22:16:46

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 22:14:51

                                     

                                     

                                     

                                     

                                    31-12-2008 22:14:51

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 22:03:35

                                     

                                     

                                     

                                     

                                    31-12-2008 22:03:35

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 21:55:03

                                     

                                     

                                     

                                     

                                    31-12-2008 21:55:03

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 21:48:44

                                     

                                     

                                     

                                     

                                    31-12-2008 21:48:44

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 21:40:13

                                     

                                     

                                     

                                     

                                    31-12-2008 21:40:13

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 21:27:32

                                     

                                     

                                     

                                     

                                    31-12-2008 21:27:32

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 21:02:07

                                     

                                     

                                     

                                     

                                    31-12-2008 21:02:07

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 19:40:32

                                     

                                     

                                     

                                     

                                    31-12-2008 19:40:32

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 17:58:48

                                     

                                     

                                     

                                     

                                    31-12-2008 17:58:48

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 17:44:23

                                     

                                     

                                     

                                     

                                    31-12-2008 17:44:23

                                     

                                     

                                     

                                    0

                                     

                                     

                                     

                                    31-12-2008 17:42:01

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     

                                     



                                     

                                    Thanks,
                                    Elisazabetta

                                    • Calculated duration time
                                      elattuca

                                       

                                       

                                      Hi All,

                                      please help me to calculate the different (hh mm ss) from orario_pre and TimeString as is :

                                       

                                      orario_pre

                                       

                                       

                                       

                                      precedente

                                       

                                       

                                       

                                      TimeString

                                       

                                       

                                       

                                      EventDuration

                                       

                                       

                                       

                                      31-12-2008 23:10:29

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 22:16:46

                                       

                                       

                                       

                                      31-12-2008 22:16:46

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 22:14:51

                                       

                                       

                                       

                                       

                                      31-12-2008 22:14:51

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 22:03:35

                                       

                                       

                                       

                                       

                                      31-12-2008 22:03:35

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 21:55:03

                                       

                                       

                                       

                                       

                                      31-12-2008 21:55:03

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 21:48:44

                                       

                                       

                                       

                                       

                                      31-12-2008 21:48:44

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 21:40:13

                                       

                                       

                                       

                                       

                                      31-12-2008 21:40:13

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 21:27:32

                                       

                                       

                                       

                                       

                                      31-12-2008 21:27:32

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 21:02:07

                                       

                                       

                                       

                                       

                                      31-12-2008 21:02:07

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 19:40:32

                                       

                                       

                                       

                                       

                                      31-12-2008 19:40:32

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 17:58:48

                                       

                                       

                                       

                                       

                                      31-12-2008 17:58:48

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 17:44:23

                                       

                                       

                                       

                                       

                                      31-12-2008 17:44:23

                                       

                                       

                                       

                                      0

                                       

                                       

                                       

                                      31-12-2008 17:42:01

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       

                                       



                                       

                                      Thanks,
                                      Elisazabetta