<?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 How to add a sequencenumber (based on date) within a same articlenumber in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216989#M70247</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you need to do it in the script, you can use functions previous() and peek() to compare the value of the Items and assign the Counter accordingly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;load&lt;BR /&gt; Item,&lt;BR /&gt; Date,&lt;BR /&gt; if(previous(Item) &amp;lt;&amp;gt; Item, 1, peek(Counter) + 1) as Counter&lt;BR /&gt;resident&lt;BR /&gt; Tab1&lt;BR /&gt;Order By&lt;BR /&gt; Item, Date&lt;BR /&gt;;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 17 Apr 2010 16:23:39 GMT</pubDate>
    <dc:creator>Oleg_Troyansky</dc:creator>
    <dc:date>2010-04-17T16:23:39Z</dc:date>
    <item>
      <title>How to add a sequencenumber (based on date) within a same articlenumber</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216988#M70246</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I need to create %2TalSeq:&lt;/P&gt;&lt;P&gt;Within the same value of %2Tal , the numbering has to restart at 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse; width: 222pt;" width="294"&gt;&lt;COL style="width: 74pt;" width="98" /&gt;&lt;COL style="width: 74pt;" width="98" /&gt;&lt;COL style="width: 74pt;" width="98" /&gt;&lt;TBODY&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl65" height="17" style="height: 12.75pt; width: 74pt;" width="98"&gt;%2Tal&lt;/TD&gt;&lt;TD class="xl65" style="border-left: medium none; width: 74pt;" width="98"&gt;Date&lt;/TD&gt;&lt;TD class="xl65" style="border-left: medium none; width: 74pt;" width="98"&gt;%2TalSeq&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°2°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;26-12-2008&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°3°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;14-05-2004&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°3°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;10-12-2004&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°3°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;29-09-2006&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°3°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;24-08-2007&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;4&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°4°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;09-04-2004&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°4°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;26-11-2004&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°4°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;27-07-2007&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°5°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;12-02-2010&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°6°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;25-11-2005&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD class="xl66" height="17" style="border-top: medium none; height: 12.75pt;"&gt;°1°6°&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: medium none; border-left: medium none;"&gt;29-09-2006&lt;/TD&gt;&lt;TD align="right" class="xl68" style="border-top: medium none; border-left: medium none;"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Paul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 17 Apr 2010 15:30:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216988#M70246</guid>
      <dc:creator />
      <dc:date>2010-04-17T15:30:08Z</dc:date>
    </item>
    <item>
      <title>How to add a sequencenumber (based on date) within a same articlenumber</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216989#M70247</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you need to do it in the script, you can use functions previous() and peek() to compare the value of the Items and assign the Counter accordingly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;load&lt;BR /&gt; Item,&lt;BR /&gt; Date,&lt;BR /&gt; if(previous(Item) &amp;lt;&amp;gt; Item, 1, peek(Counter) + 1) as Counter&lt;BR /&gt;resident&lt;BR /&gt; Tab1&lt;BR /&gt;Order By&lt;BR /&gt; Item, Date&lt;BR /&gt;;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 17 Apr 2010 16:23:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216989#M70247</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2010-04-17T16:23:39Z</dc:date>
    </item>
    <item>
      <title>How to add a sequencenumber (based on date) within a same articlenumber</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216990#M70248</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oleg,&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;Paul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 18 Apr 2010 20:08:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-add-a-sequencenumber-based-on-date-within-a-same/m-p/216990#M70248</guid>
      <dc:creator />
      <dc:date>2010-04-18T20:08:57Z</dc:date>
    </item>
  </channel>
</rss>

