<?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: Peek Keyfield Value based on 2 Fields in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131652#M605935</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;I don't know why but I did not succeed to post the tables structure as I see it&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;(You'll find it in the attached text file)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 11 Jul 2018 14:23:59 GMT</pubDate>
    <dc:creator>seWork</dc:creator>
    <dc:date>2018-07-11T14:23:59Z</dc:date>
    <item>
      <title>Peek Keyfield Value based on 2 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131651#M605934</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to peek a value as part of loop script(For i = 1 to X)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The script should be based on 2 fields from an existing table&lt;/P&gt;&lt;P&gt;-Date&lt;/P&gt;&lt;P&gt;-Category&lt;/P&gt;&lt;P&gt;so the script will peek and line based on field "Keyfield" as many times as set by these two parameters in the "Secondary table"&lt;/P&gt;&lt;P&gt;(The Keyfield will be duplicate and then i will join the rest of fields by left join)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;after this part will be done I would like to replace the Part_ID value in the &lt;SPAN style="font-size: 13.3333px;"&gt;New table based on random peeking &lt;SPAN style="font-size: 13.3333px;"&gt;Part_ID form the same category(And to change the &lt;SPAN style="font-size: 13.3333px;"&gt;Keyfield value to a new value by using "'FE-'&amp;amp;Keyfield as Keyfield"&amp;nbsp;&amp;nbsp; in order to keep each value unique)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;and to concatenate the "new table" with the "source table"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are any suggestions on what will be the best way to execute it?&lt;/P&gt;&lt;P&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>Wed, 11 Jul 2018 14:15:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131651#M605934</guid>
      <dc:creator>seWork</dc:creator>
      <dc:date>2018-07-11T14:15:31Z</dc:date>
    </item>
    <item>
      <title>Re: Peek Keyfield Value based on 2 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131652#M605935</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;I don't know why but I did not succeed to post the tables structure as I see it&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;(You'll find it in the attached text file)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jul 2018 14:23:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131652#M605935</guid>
      <dc:creator>seWork</dc:creator>
      <dc:date>2018-07-11T14:23:59Z</dc:date>
    </item>
    <item>
      <title>Re: Peek Keyfield Value based on 2 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131653#M605936</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I tried to begin to solve it it by running the following script but I'm getting an error&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Table not found error&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Table 'TempOrderLines' not found&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;store TempOrderLines into OrderLinesGen/TempOrderLines0.QVD&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;(At the moment im running the script for the Date only)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Order_Dates:&lt;/P&gt;&lt;P&gt;Load Distinct Date Resident OrderHeader;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let QyDate = FieldValuecount(FieldName(1,'Order_Dates'));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MinDate:&lt;/P&gt;&lt;P&gt;Load Distinct MIN(Date) as Mindate Resident Order_Dates;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let vMinDate = Peek('Mindate',-1,'MinDate');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop table Order_Dates;&lt;/P&gt;&lt;P&gt;Drop TABLE MinDate;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For gDate = 0 to QyDate&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TempOrderLines:&lt;/P&gt;&lt;P&gt;First (10)&lt;/P&gt;&lt;P&gt;Load * Resident Order_line&lt;/P&gt;&lt;P&gt;where Date=date($(vMinDate)+$(gDate));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;store TempOrderLines into OrderLinesGen/TempOrderLines$(gDate).QVD;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Next gDate;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2018 07:33:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Peek-Keyfield-Value-based-on-2-Fields/m-p/131653#M605936</guid>
      <dc:creator>seWork</dc:creator>
      <dc:date>2018-07-12T07:33:03Z</dc:date>
    </item>
  </channel>
</rss>

