2 Replies Latest reply: Jul 23, 2015 9:21 AM by Qlik Dev RSS

    How to calculate seconds diff.

      Hi All,

       

      I Load the sample data this way and want to get difference in the seconds how can i do this in script in place of this

      Interval( [Close Date Time] - [Create Date Time], 'DD' )  want to get seconds difference in script and then average.

       

      LOAD

      *,

      Interval( [Close Date Time] - [Create Date Time], 'DD' )  AS DiffDays

      FROM DataSource;


      Now in front end just use

      Sum(DiffDays)/Count(Id)


      And calculate Average in bar chart this way.


      Dim : Region

      Expression :- Sum(DiffDays)/Count(Id)


      Note:- Here my question is what is the unit of measurement of this average calculation in expression.


      I attached the sample data.


      Any one reply on this.


      Thanks,

      Bosc