<?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 Re: Timestamp with iterno() bug in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1816432#M66827</link>
    <description>&lt;P&gt;Yes, you couldn't use maketime() in this scenario because you didn't trigger the next hour if you reach 60 minutes - probably there would be also measures to implement such logic with maketime() but I think it would be far much complicated as necessary and therefore I suggest something like:&lt;/P&gt;&lt;P&gt;timestamp(floor(FromDate + (1/24/60 * (iterno()-1)), 1/24/60))&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
    <pubDate>Mon, 21 Jun 2021 06:10:55 GMT</pubDate>
    <dc:creator>marcus_sommer</dc:creator>
    <dc:date>2021-06-21T06:10:55Z</dc:date>
    <item>
      <title>Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747106#M57392</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I am trying generate timestamp for every 1 minute of interval between start date and end. I found the way of doing it but facing issue as in some scenario it is behaving strange. I am not sure if I am doing wrong , need your help.&lt;/P&gt;&lt;P&gt;I am running below script&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Data:
LOAD *,
timestamp(Start_Date+MakeTime(0,IterNo()-1)) as Time
While Start_Date+MakeTime(0,IterNo()-1)&amp;lt;=End_Date;
LOAD * Inline [
Start_Date,End_Date
10/20/2020 10:00,10/20/2020 10:07 ];&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For a interval defined above, I am getting correct output which is generating time from 10:00 to 10:07. But as soon as I put below interval with same script, it is not giving correct results.&lt;/P&gt;&lt;P&gt;Data:&lt;BR /&gt;LOAD *,&lt;BR /&gt;timestamp(Start_Date+MakeTime(0,IterNo()-1)) as Time&lt;BR /&gt;While Start_Date+MakeTime(0,IterNo()-1)&amp;lt;=End_Date;&lt;BR /&gt;LOAD * Inline [&lt;BR /&gt;Start_Date,End_Date&lt;BR /&gt;&lt;STRONG&gt;10/20/2020 11:00,10/20/2020 11:07&lt;/STRONG&gt; ];&lt;/P&gt;&lt;P&gt;Above script generates time only till 11:06 with missing 11:07. Not sure if it is bug or I am doing something wrong. Can you please advise?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 09:35:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747106#M57392</guid>
      <dc:creator>Sagar_Apte</dc:creator>
      <dc:date>2020-09-25T09:35:08Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747154#M57394</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28038"&gt;@marcus_sommer&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/22245"&gt;@swuehl&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/22949"&gt;@tresB&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/46628"&gt;@sunny_talwar&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/336"&gt;@Kushal_Chawda&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 11:56:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747154#M57394</guid>
      <dc:creator>Sagar_Apte</dc:creator>
      <dc:date>2020-09-25T11:56:02Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747157#M57396</link>
      <description>&lt;P&gt;It's not a matter from iterno() else from the in Qlik used binary number system. Therefore try it in this way:&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Data:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LOAD *,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;timestamp(floor(Start_Date+MakeTime(0,IterNo()-1), 1/24/60)) as Time&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;While floor(Start_Date+MakeTime(0,IterNo()-1), 1/24/60) &amp;lt;=&lt;STRONG&gt;floor(&lt;/STRONG&gt;End_Date,&lt;STRONG&gt; 1/24/60)&lt;/STRONG&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LOAD * Inline [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Start_Date,End_Date&lt;/SPAN&gt;&lt;BR /&gt;10/20/2020 11:00,10/20/2020 11:07&lt;SPAN&gt;&amp;nbsp;];&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 12:05:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747157#M57396</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2020-09-25T12:05:01Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747169#M57397</link>
      <description>&lt;P&gt;It is a tiny decimal difference between the numeric representation of&amp;nbsp;10/20/2020 11:07 and&amp;nbsp;(Start_Date+MakeTime(0,&lt;FONT color="#808080"&gt;8&lt;/FONT&gt;-1))&lt;/P&gt;&lt;P&gt;Numeric of 10/20/2020 11:07&amp;nbsp; is:&amp;nbsp;44&amp;nbsp;124,4631944444&lt;STRONG&gt;4&lt;/STRONG&gt;000&lt;/P&gt;&lt;P&gt;Numeric of&amp;nbsp;&amp;nbsp;(Start_Date+MakeTime(0,&lt;FONT color="#808080"&gt;8&lt;/FONT&gt;-1)) is&amp;nbsp;44&amp;nbsp;124,4631944444&lt;STRONG&gt;5&lt;/STRONG&gt;000&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I reccomend you to round your timestapt down to seconds. Like this:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Data:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;LOAD &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp;*,&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp;IterNo() as Iterno,&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp;timestamp(Start_Date+MakeTime(0,IterNo()-1)) as Time&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;While &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp;round(Start_Date+MakeTime(0,IterNo()-1),1/1440)&amp;lt;=round(End_Date,1/1440);&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;LOAD * Inline [&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Start_Date,End_Date&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;10/20/2020 11:00,10/20/2020 11:07&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;10/20/2020 10:00,10/20/2020 10:07 ];&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 12:29:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747169#M57397</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2020-09-25T12:29:37Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747180#M57398</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/121297"&gt;@Sagar_Apte&lt;/a&gt;&amp;nbsp; as mentioned by&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/25001"&gt;@Vegar&lt;/a&gt;&amp;nbsp; &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28038"&gt;@marcus_sommer&lt;/a&gt;&amp;nbsp;&amp;nbsp;it could be due to decimal difference of your time part, you could probably also allow interno() to loop for actual minute difference of your start and end date like below to avoid any conversion issues&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Data:
LOAD *,
     timestamp(Start_Date+MakeTime(0,IterNo()-1)) as Time
While IterNo()&amp;lt;= Minute(End_Date-Start_Date)+1; 
LOAD * Inline [
Start_Date,End_Date
10/20/2020 11:00,10/20/2020 11:07
10/20/2020 10:00,10/20/2020 10:07 ];&lt;/LI-CODE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2020-09-25 140615.png" style="width: 448px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/41224i790A3759C541B9C6/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2020-09-25 140615.png" alt="Screenshot 2020-09-25 140615.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 13:12:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747180#M57398</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2020-09-25T13:12:15Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747191#M57401</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28038"&gt;@marcus_sommer&lt;/a&gt;&amp;nbsp; &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/25001"&gt;@Vegar&lt;/a&gt;&amp;nbsp; &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/336"&gt;@Kushal_Chawda&lt;/a&gt;&amp;nbsp; Thank you so much for the explanation. It is really helpful. Now I am confused which one I accept as solution as all are correct. Marcus was first so should I mark that as correct one?&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 13:31:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747191#M57401</guid>
      <dc:creator>Sagar_Apte</dc:creator>
      <dc:date>2020-09-25T13:31:22Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747192#M57402</link>
      <description>&lt;P&gt;Personally I prefer an equally rounding each time a time/timestamp is loaded or created/calculated to ensure that they always match in the expected way and there might be various other occasions in the script or the UI where such a match is performed.&lt;/P&gt;&lt;P&gt;In this case it's quite obvious why it didn't work but to find this issue in a join which only lost a few records (which may only happens later with real-data and not during the development) or within complex set analysis it might take much longer to realize the true cause (and I did already run into it a few times ...).&lt;/P&gt;&lt;P&gt;- Marcus&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 13:35:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747192#M57402</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2020-09-25T13:35:57Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747196#M57403</link>
      <description>&lt;P&gt;AFAIK you could mark several answers as correct.&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 13:37:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747196#M57403</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2020-09-25T13:37:50Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747202#M57407</link>
      <description>&lt;P&gt;Thank you all once again&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 13:52:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1747202#M57407</guid>
      <dc:creator>Sagar_Apte</dc:creator>
      <dc:date>2020-09-25T13:52:55Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815834#M66762</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28038"&gt;@marcus_sommer&lt;/a&gt;&amp;nbsp; and&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/25001"&gt;@Vegar&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;i had the same issue, and your solution works fine, but (in my case ?) only until 60 iterations, then it stops. is there a solution for this problem as well, for example it the duration is about 2.5 hours?&amp;nbsp;&lt;BR /&gt;I tried with timestamp but did non manage to find a proper solution &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;i would be very glad if you could help me.&amp;nbsp;&lt;/P&gt;&lt;P&gt;greetings jakob&lt;/P&gt;</description>
      <pubDate>Thu, 17 Jun 2021 14:35:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815834#M66762</guid>
      <dc:creator>jakobjosef</dc:creator>
      <dc:date>2021-06-17T14:35:33Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815841#M66763</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlik_17.06.2021.JPG" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/57000iD0C1796EF700C7D4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlik_17.06.2021.JPG" alt="qlik_17.06.2021.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 17 Jun 2021 14:37:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815841#M66763</guid>
      <dc:creator>jakobjosef</dc:creator>
      <dc:date>2021-06-17T14:37:51Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815872#M66764</link>
      <description>&lt;P&gt;Iterno() hasn't any inbuilt limitation else it will run as far as the while-condition is true. This means you should check this condition again if it's really based on a minute-difference between from and to.&lt;/P&gt;&lt;P&gt;Before - just check the set selections in your application if not any of them limit your view from the screenshot to the 8'th hour.&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Thu, 17 Jun 2021 15:10:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815872#M66764</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2021-06-17T15:10:33Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815984#M66771</link>
      <description>&lt;P&gt;Dear&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28038"&gt;@marcus_sommer&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;thank you very much for your answer. Unfortunately I could not find the problem.&lt;BR /&gt;But I made a very short example, using exactly your solution, maybe you could check it&amp;nbsp; ?&lt;BR /&gt;This is the script :&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Qlik_18.06.2021.JPG" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/57066i01B08859D4337061/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Qlik_18.06.2021.JPG" alt="Qlik_18.06.2021.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The file is attached. I would be very happy if there is a solution to this problem.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Greetings&lt;BR /&gt;Jakob&lt;/P&gt;&lt;P&gt; &lt;/P&gt;</description>
      <pubDate>Fri, 18 Jun 2021 06:43:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1815984#M66771</guid>
      <dc:creator>jakobjosef</dc:creator>
      <dc:date>2021-06-18T06:43:54Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1816001#M66773</link>
      <description>&lt;P&gt;Could it be, that "maketime" can only add 59 minutes at the "minutes-spot"? so we would need to go on with the "hour-spot"?&lt;/P&gt;</description>
      <pubDate>Fri, 18 Jun 2021 07:57:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1816001#M66773</guid>
      <dc:creator>jakobjosef</dc:creator>
      <dc:date>2021-06-18T07:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: Timestamp with iterno() bug</title>
      <link>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1816432#M66827</link>
      <description>&lt;P&gt;Yes, you couldn't use maketime() in this scenario because you didn't trigger the next hour if you reach 60 minutes - probably there would be also measures to implement such logic with maketime() but I think it would be far much complicated as necessary and therefore I suggest something like:&lt;/P&gt;&lt;P&gt;timestamp(floor(FromDate + (1/24/60 * (iterno()-1)), 1/24/60))&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Mon, 21 Jun 2021 06:10:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Timestamp-with-iterno-bug/m-p/1816432#M66827</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2021-06-21T06:10:55Z</dc:date>
    </item>
  </channel>
</rss>

