<?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: how to create an unique key based on previous values in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401150#M701453</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sort is not going to work, as if I take the examble above&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="139"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemA&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemB&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Key&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;AAA&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;BBB&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;AAA&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;CCC&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;EEE&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;FFF&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;&lt;STRONG&gt;AAA&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;HHH&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;&lt;STRONG&gt;Key0&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;LLL&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;MMM&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key2&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then let say I add the line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="24" style="border: 1px solid rgb(0, 0, 0); width: 130px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;MMM&lt;/TD&gt;&lt;TD&gt;BBB&lt;/TD&gt;&lt;TD&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as you see the Key has to be Key0, because BBB needs to be chainded to the (AAA) BBB.&lt;/P&gt;&lt;P&gt;But because of sort, this new line will stay after the last line of the existing table, therefore generating a new Key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I think is rather complicate, I have to find a way for each new line to look back at ALL previous lines and check against the new values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Oct 2012 08:47:34 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-10-12T08:47:34Z</dc:date>
    <item>
      <title>how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401144#M701447</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear guys&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a sort of a puzzle (for me); for you I think is something really easy! &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/wink.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let say I have a list of items&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="185" style="border: 1px solid rgb(0, 0, 0); width: 247px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;ItemA&lt;BR /&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;ItemB&lt;BR /&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;Chain&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;A&lt;/TD&gt;&lt;TD&gt;B&lt;/TD&gt;&lt;TD&gt;Key0001&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;D&lt;/TD&gt;&lt;TD&gt;E&lt;/TD&gt;&lt;TD&gt;Key0002&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;D&lt;/TD&gt;&lt;TD&gt;F&lt;/TD&gt;&lt;TD&gt;Key0002&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;G&lt;/TD&gt;&lt;TD&gt;H&lt;/TD&gt;&lt;TD&gt;Key0003&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;L&lt;/TD&gt;&lt;TD&gt;N&lt;/TD&gt;&lt;TD&gt;Key0004&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;M&lt;/TD&gt;&lt;TD&gt;N&lt;/TD&gt;&lt;TD&gt;Key0004&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;P&lt;/TD&gt;&lt;TD&gt;A&lt;/TD&gt;&lt;TD&gt;Key0001&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;I think it speaks for itself, but I will try in my own words.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to create, out of a table with two fields (ItemA and ItemB), a new field "Chain" which assigns a Key.&lt;/P&gt;&lt;P&gt;This Key is generated according to what is the content in ItemA and ItemB.&lt;/P&gt;&lt;P&gt;If the two fields contain brand new values, then a new Key is created in the Chain field.&lt;/P&gt;&lt;P&gt;Otherwise, if it in ItemA/B there is an item which is previously in the list, it should assign the Key which was assigned previously.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it a hard task?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Oct 2012 14:54:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401144#M701447</guid>
      <dc:creator />
      <dc:date>2012-10-10T14:54:17Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401145#M701448</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I usually hate to bump, but is the question not so clear, or is the problem untackleable? &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/plain.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 09:43:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401145#M701448</guid>
      <dc:creator />
      <dc:date>2012-10-11T09:43:47Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401146#M701449</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've got somewhere 1 inch further and wrote down this piece of script&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_13499652729158257" jivemacro_uid="_13499652729158257"&gt;&lt;P&gt;LOAD ItemA, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ItemB&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[\IC_test.xlsx]&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vMaxRow = NoOfRows('Sheet1'); //get the tot number of rows in source table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For vValueNo=1 to $(vMaxRow) //loop through every row&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NewTable:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;ItemA,&lt;/P&gt;&lt;P&gt;ItemB,&lt;/P&gt;&lt;P&gt;if(peek('ItemA',$(vValueNo),'Sheet1') &amp;lt;&amp;gt; peek('ItemA',($(vValueNo)-1),'Sheet1'), 'Key'&amp;amp;$(vValueNo), 'SAME') as Chain&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RESIDENT Sheet1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NEXT vValueNo&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop table Sheet1;&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;expectations:&lt;/STRONG&gt; have the script looping around my data (just one field, ItemA, to make it simpler) and check if the previous value in ItemA is the same, input SAME in the Chain field, otherwise create a value as Key&amp;amp;NumberOfTheRecord&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;result&lt;/STRONG&gt;: the script picks up the whole table Sheet1 and attaches a 'Key1' value in the Chain field; then it picks up again the whole table, and attaches a 'Key2' and so forth.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Given my complete lack of experience in programming, I'm quite happy about my result, at least I managed to get a loop started; but still I'm a long way to reach what I want (have the script check current value against ALL the previous values, and if happens to be a new value, assign a new key, else assign the same key as the old value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any hint will be much, much appreciated!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 14:29:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401146#M701449</guid>
      <dc:creator />
      <dc:date>2012-10-11T14:29:42Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401147#M701450</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 think you're close but when you are creating NewTable, instead of doing Resident Sheet1 do AutoGenerate(1). This will only create one line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You will need to change a few things before this too so it'll look something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vPrevItemA = null();&lt;/P&gt;&lt;P&gt;let vPrevItemB = null();&lt;/P&gt;&lt;P&gt;let vChain = null();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class="jive-code"&gt;For vValueNo=0 to $(vMaxRow)-1 //Changed this to help with peeks (0 indexed)&lt;BR /&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; let vItemA = peek('ItemA',$(vValueNo),'Sheet1');&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; let vItemB = peek('ItemB',$(vValueNo),'Sheet1');&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: monospace;"&gt;if '$(vItemA)'&amp;lt;&amp;gt;'$(vPrevItemA)' then&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: monospace;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; let vChain = 'Key'&amp;amp;$(vValueNo);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: monospace;"&gt;&amp;nbsp;&amp;nbsp; endif;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class="jive-code"&gt;&lt;BR /&gt;NewTable:&lt;BR /&gt;LOAD&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '$(vItemA)' as ItemA,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '$(vItemB)' as ItemB,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '$(vChain)' as Chain&lt;BR /&gt;autogenerate(1);&lt;BR /&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vPrevItemA = '$(vItemA)';&lt;/P&gt;&lt;P&gt;let vPrevItemB = '$(vItemB)';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class="jive-code"&gt;&lt;BR /&gt;NEXT vValueNo;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It's off the top of my head so may need a bit of tinkering with to get it to work!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 15:33:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401147#M701450</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-11T15:33:06Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401148#M701451</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Chris,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;your help was of great value!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I really made a gigantic leap and it is starting to get closer to what I want.&lt;/P&gt;&lt;P&gt;The first small issue that I have is that if my source table looks like this &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="139" style="border: 1px solid rgb(0, 0, 0); width: 357px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemA&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemB&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Key&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;AAA&lt;/TD&gt;&lt;TD&gt;BBB&lt;/TD&gt;&lt;TD&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;AAA&lt;/TD&gt;&lt;TD&gt;CCC&lt;/TD&gt;&lt;TD&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;EEE&lt;/TD&gt;&lt;TD&gt;FFF&lt;/TD&gt;&lt;TD&gt;Key1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;STRONG&gt;AAA&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD&gt;HHH&lt;/TD&gt;&lt;TD&gt;&lt;STRONG&gt;Key0&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;LLL&lt;/TD&gt;&lt;TD&gt;MMM&lt;/TD&gt;&lt;TD&gt;Key2&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it is important that line 4, since it contains AAA which was already in lines 1 and 2, still keeps the same key as the first ones, hence Key0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And then, on a second phase, I will need my check for a new line to be done both on ItemA AND ItemB, by looking back both at ItemA AND ItemB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But, as said before, this oen of yours was already an outstanding hint in the right direction, thank you so much!&lt;/P&gt;&lt;P&gt;I definitely have some material to work upon tomorrow &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 15:52:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401148#M701451</guid>
      <dc:creator />
      <dc:date>2012-10-11T15:52:43Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401149#M701452</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ah, ok!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For your first problem maybe you need to sort your data first on ItemA,ItemB before going into the loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm not sure if you can sort the data when you are loading from Excel though so you may need to load it into QlikView first and then sort it by loading the data again. Check if you can sort it on the load from Excel first though.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will leave you to have a go at your second problem but you should have most of what you need&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2012 16:08:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401149#M701452</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-11T16:08:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401150#M701453</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sort is not going to work, as if I take the examble above&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="139"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemA&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;ItemB&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;TH align="center" style="border: 1px solid #000000; background-color: #6690bc;" valign="middle"&gt;&lt;SPAN style="color: #ffffff;"&gt;&lt;STRONG&gt;Key&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;AAA&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;BBB&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;AAA&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;CCC&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;EEE&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;FFF&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;&lt;STRONG&gt;AAA&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;HHH&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;&lt;STRONG&gt;Key0&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: 1px solid #000000;"&gt;LLL&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;MMM&lt;/TD&gt;&lt;TD style="border: 1px solid #000000;"&gt;Key2&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then let say I add the line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" cellpadding="3" cellspacing="0" class="jiveBorder" height="24" style="border: 1px solid rgb(0, 0, 0); width: 130px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;MMM&lt;/TD&gt;&lt;TD&gt;BBB&lt;/TD&gt;&lt;TD&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as you see the Key has to be Key0, because BBB needs to be chainded to the (AAA) BBB.&lt;/P&gt;&lt;P&gt;But because of sort, this new line will stay after the last line of the existing table, therefore generating a new Key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I think is rather complicate, I have to find a way for each new line to look back at ALL previous lines and check against the new values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 08:47:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401150#M701453</guid>
      <dc:creator />
      <dc:date>2012-10-12T08:47:34Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401151#M701454</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;Had a bit of a play around and feel like I'm getting closer. Have changed some of the functions I'm using, have a look and see what you think!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 09:24:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401151#M701454</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T09:24:45Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401152#M701455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Chris,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is really another greatly helpful step.&lt;/P&gt;&lt;P&gt;Now I just need to adjust the if statements for having the script cross-looking both at ItemA and ItemB, and I will get what I need!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but I will try on my own, now the nasty variables/loop part is sorted, I think I can handle myself with setting up rightly the IF statements...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will come back here, really thank you very much again for your valuable help!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 09:37:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401152#M701455</guid>
      <dc:creator />
      <dc:date>2012-10-12T09:37:36Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401153#M701456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Glad I could help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm sure you'll be whizzing through this in no time, it just takes a little practise and knowledge of a few key functions that you may not have used before.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 09:40:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401153#M701456</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T09:40:45Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401154#M701457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, it took me a little more than no time, but I'm getting even closer.&lt;/P&gt;&lt;P&gt;Please see attached, if you are still willing to lend a hand.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But indeed I am facing a structural problem, as, if this is the table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE bgcolor="#ffffff" border="1" cellpadding="2" cellspacing="0" height="201" style="font-size: 9pt; width: 173px;"&gt;&lt;TBODY&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;ItemA&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;ItemB&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Chain&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;AAA&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;BBB&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key0&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;AAA&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;HHH&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key0&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;AAA&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;QQQ&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key0&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;HHH&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;ZZZ&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;Key0&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;LLL&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;MMM&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key1&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;MMM&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;BBB&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;Key1...but Key0 too!!&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;NNN&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;OOO&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key2&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;QQQ&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;TTT&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;Key1&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;RRR&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;AAA&lt;/SPAN&gt; &lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;Key0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The entry MMM - BBB creates a problem, as it is part of two "chains" and the script cannot go back to the previously entered record, to which a new chain key was assigned, and change the Key from Key1 to Key0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But besides this structural problem (this situation I'm not expecting to happen in real life) some fields still stays empty.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Again, if you fancy giving it a last revision, it will be much appreciated!&lt;/P&gt;&lt;P&gt;thank you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 11:34:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401154#M701457</guid>
      <dc:creator />
      <dc:date>2012-10-12T11:34:28Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401155#M701458</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just to clear it up, what should be the key for the row MMM - BBB? Key 0 or key 1? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think maybe the order of the if statements may need to be re-arranged in order to get the result you want.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think I've sorted out the blank lines anyway! I took out a noconcatenate keyword which was not needed and that seemed to do the trick.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 12:42:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401155#M701458</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T12:42:27Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401156#M701459</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yep, the tricky part is that not only MMM - BBB should be Key0.&lt;/P&gt;&lt;P&gt;But the previous record, LLL-MMM, since it has the MMM key which NOW belongs to Key0, should also be changed to Key0.&lt;/P&gt;&lt;P&gt;But this is really hard to achieve and I guess such situation will never arise in real life.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will give a look to your fix, will let you know.&lt;/P&gt;&lt;P&gt;Though it seems I also reached something with a different code, which indeed does not seem logically written to me.. &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/confused.png" /&gt;&lt;/P&gt;&lt;P&gt;I attached it...&lt;/P&gt;&lt;P&gt;From a logic point of view, I really do not explain to myself how is it working...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you very much again!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 12:49:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401156#M701459</guid>
      <dc:creator />
      <dc:date>2012-10-12T12:49:54Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401157#M701460</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, there are many ways to do the same thing in QlikView!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I have done is changed the order of the if statements so that it works i the following way for the current row in the table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. If the value in ItemA matches a previous ItemA then use the key for that row&lt;/P&gt;&lt;P&gt;2. If the value in ItemB matches a previous ItemB then use the key for that row&lt;/P&gt;&lt;P&gt;3. If the value in ItemA matches a previous ItemB then use the key for that row&lt;/P&gt;&lt;P&gt;4. If the value in ItemB matches a previous ItemA then use the key for that row&lt;/P&gt;&lt;P&gt;5. If ItemA and ItemB values are unique then create a new key&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As for the problem of then assigning row LLL-MMM to Key0 then this gets trickier. I think it may need to then be re-done somehow, but I'm not sure how!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope i have been of some help anyway, and hopefully you have learnt a few tricks &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:11:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401157#M701460</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T13:11:36Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401158#M701461</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;Chris Abwat-Johnson wrote:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, there are many ways to do the same thing in QlikView!&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that is the positive and negative side of it &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your conditions, as you wrote them down, sounds good.&lt;/P&gt;&lt;P&gt;and easily tweakable if I will need to change it (to eventually fits at best the "tricky scenario")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but the file you attached seems the old version to me, I think is the same one as the first you posted today...&lt;/P&gt;&lt;P&gt;Can you please double check?&lt;/P&gt;&lt;P&gt;Thank you again for all of your effort!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:16:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401158#M701461</guid>
      <dc:creator />
      <dc:date>2012-10-12T13:16:59Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401159#M701462</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh, I'm not sure. What is the value for the Chain column for row MMM-BBB? In the current version I have it is Key0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have attached it again, but it may be the same as before! Maybe I didn't save the file before I attached it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:22:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401159#M701462</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T13:22:43Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401160#M701463</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;MMM-BBB is indeed Key0 as it is supposed to be, but the cross-check within the two fields is not working and the script is the same (I know it almost by heart now &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/silly.png" /&gt;) as that awesome piece of script that you post this morning, that fixed the issue of looking back in the whole range (of the same field) instead of just the previous value..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I'm afraid you didn't hit the save button!&lt;/P&gt;&lt;P&gt;pity, but maybe I can sort something out with that "odd" version of mine that I attached..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks! &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:38:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401160#M701463</guid>
      <dc:creator />
      <dc:date>2012-10-12T13:38:44Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401161#M701464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, sorry. My fault! Try this one, although I'm a bit lost with them all now!&amp;nbsp; &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/confused.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:44:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401161#M701464</guid>
      <dc:creator>chris_johnson</dc:creator>
      <dc:date>2012-10-12T13:44:29Z</dc:date>
    </item>
    <item>
      <title>Re: how to create an unique key based on previous values</title>
      <link>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401162#M701465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;script-wise it defintiely looks new to me.&lt;/P&gt;&lt;P&gt;will check and let you know asap! &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Oct 2012 13:45:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/how-to-create-an-unique-key-based-on-previous-values/m-p/401162#M701465</guid>
      <dc:creator />
      <dc:date>2012-10-12T13:45:56Z</dc:date>
    </item>
  </channel>
</rss>

