<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Calculating Elapsed Time in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Calculating-Elapsed-Time/m-p/561577#M1135533</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am very new to QlikView so apologies is my question is quite basic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to build a bar chart in QV to show the distribution of elapsed time in days between tasks for each case in a process.&lt;/P&gt;&lt;P&gt;My x axis should show the number of days and&amp;nbsp; my y axis will show the number of cases.&lt;/P&gt;&lt;P&gt;My data contains a completion date for each task as the cases moves through the process. To calculate the time per task I need to use the completion date of one task less the completion date of the previous task.&lt;/P&gt;&lt;P&gt;I have made numerous attempts at creating the chart without any succes so any help would be very much apreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hopefully I've made myself clear.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 15 Oct 2013 13:18:55 GMT</pubDate>
    <dc:creator />
    <dc:date>2013-10-15T13:18:55Z</dc:date>
    <item>
      <title>Calculating Elapsed Time</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Elapsed-Time/m-p/561577#M1135533</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am very new to QlikView so apologies is my question is quite basic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to build a bar chart in QV to show the distribution of elapsed time in days between tasks for each case in a process.&lt;/P&gt;&lt;P&gt;My x axis should show the number of days and&amp;nbsp; my y axis will show the number of cases.&lt;/P&gt;&lt;P&gt;My data contains a completion date for each task as the cases moves through the process. To calculate the time per task I need to use the completion date of one task less the completion date of the previous task.&lt;/P&gt;&lt;P&gt;I have made numerous attempts at creating the chart without any succes so any help would be very much apreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hopefully I've made myself clear.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Oct 2013 13:18:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Elapsed-Time/m-p/561577#M1135533</guid>
      <dc:creator />
      <dc:date>2013-10-15T13:18:55Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Elapsed Time</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Elapsed-Time/m-p/561578#M1135536</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It would be helpful, if you could post some sample lines of data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In principle, I would calculate the duration of a task in the script, since the duration should not depend on selections.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use peek() function to access the previous row when reading in your data, in a simple version like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Task,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EndDate,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EndDate - peek(EndDate) as Duration&lt;/P&gt;&lt;P&gt;FROM ...;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then use Duration field as dimension and count(Task) as expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;edit: You need to take care of the order of your input data, so you may need to add a sort by EndDate&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Oct 2013 13:35:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Elapsed-Time/m-p/561578#M1135536</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2013-10-15T13:35:42Z</dc:date>
    </item>
  </channel>
</rss>

