<?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 get peek data with a condition? in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847736#M70082</link>
    <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;May be this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;YourDB_Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Your_DB_Fields&lt;/P&gt;&lt;P&gt;From Your_DB;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Your_Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Your_Fields,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; If ( vin = Previous(vin) , Previous(location), location)&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;As Last_Location&lt;/P&gt;&lt;P&gt;Resident YourDB_Table&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Order By&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; vin, YOUR_DATE_FIELD&amp;nbsp; &amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Asc;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Drop Table&amp;nbsp;YourDB_Table;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, as&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/675"&gt;@MarcoWedel&lt;/a&gt;&amp;nbsp;said, you should be able to order resident table by vin and datetime field ascending (from older to newer values).&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;</description>
    <pubDate>Sun, 17 Oct 2021 05:25:14 GMT</pubDate>
    <dc:creator>Thiago_Justen_</dc:creator>
    <dc:date>2021-10-17T05:25:14Z</dc:date>
    <item>
      <title>How to get peek data with a condition?</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847557#M70055</link>
      <description>&lt;P&gt;Hello everyone!&lt;/P&gt;&lt;P&gt;I've tried to search if this was already solved on the forum but without luck.&lt;/P&gt;&lt;P&gt;I need to get the location from the last same 'vin' (vehicle identification number).&lt;/P&gt;&lt;P&gt;Right now I have the following: &lt;EM&gt;IF(vin = PEEK(vin),Peek(location)) AS peekLocation&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;But if vin &amp;lt;&amp;gt; peek(vin) then I don't know how to fetch the next most recent vin.&lt;/P&gt;&lt;P&gt;See the attached image to see the real data.&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Fri, 15 Oct 2021 17:15:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847557#M70055</guid>
      <dc:creator>Polido</dc:creator>
      <dc:date>2021-10-15T17:15:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to get peek data with a condition?</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847621#M70061</link>
      <description>&lt;P&gt;you have to order by vin during load.&lt;BR /&gt;Please post some data as well as your expected result.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Marco&lt;/P&gt;</description>
      <pubDate>Fri, 15 Oct 2021 20:49:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847621#M70061</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2021-10-15T20:49:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to get peek data with a condition?</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847736#M70082</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;May be this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;YourDB_Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Your_DB_Fields&lt;/P&gt;&lt;P&gt;From Your_DB;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Your_Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Your_Fields,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; If ( vin = Previous(vin) , Previous(location), location)&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;As Last_Location&lt;/P&gt;&lt;P&gt;Resident YourDB_Table&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Order By&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; vin, YOUR_DATE_FIELD&amp;nbsp; &amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Asc;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Drop Table&amp;nbsp;YourDB_Table;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, as&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/675"&gt;@MarcoWedel&lt;/a&gt;&amp;nbsp;said, you should be able to order resident table by vin and datetime field ascending (from older to newer values).&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;</description>
      <pubDate>Sun, 17 Oct 2021 05:25:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1847736#M70082</guid>
      <dc:creator>Thiago_Justen_</dc:creator>
      <dc:date>2021-10-17T05:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to get peek data with a condition?</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1860619#M71009</link>
      <description>&lt;P&gt;Thank you very much for the help, it works!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Nov 2021 17:46:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-get-peek-data-with-a-condition/m-p/1860619#M71009</guid>
      <dc:creator>Polido</dc:creator>
      <dc:date>2021-11-17T17:46:52Z</dc:date>
    </item>
  </channel>
</rss>

