<?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 retrieve the value from a field corresponding to the latest date in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477822#M100409</link>
    <description>&lt;P&gt;Try this also, much simpler -&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Max(Total&amp;lt;Date&amp;gt; Value)&lt;/P&gt;</description>
    <pubDate>Sat, 24 Aug 2024 04:02:48 GMT</pubDate>
    <dc:creator>Digvijay_Singh</dc:creator>
    <dc:date>2024-08-24T04:02:48Z</dc:date>
    <item>
      <title>How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477814#M100406</link>
      <description>&lt;P&gt;hello,&lt;BR /&gt;&lt;BR /&gt;Here's the mockup of my data:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikbbguser_0-1724451919785.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170942iA14A64CC4EAC517D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikbbguser_0-1724451919785.png" alt="qlikbbguser_0-1724451919785.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wanted to&lt;/P&gt;
&lt;P&gt;(1) create a calculation/expression to retrieve the value as of latest date based on the Date field, and put into a KPI chart as the measure.&lt;/P&gt;
&lt;P&gt;(2) I also want the KPI box to be driven by the filter of Customer&lt;/P&gt;
&lt;P&gt;So if I select Wholefoods in the filter, I want the 500 to be displayed in the KPI chart.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;How can I achieve this? Thank you !!!!&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2024 22:25:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477814#M100406</guid>
      <dc:creator>qlikbbguser</dc:creator>
      <dc:date>2024-08-23T22:25:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477815#M100407</link>
      <description>&lt;P&gt;Here are a couple of solutions from the community:&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.qlik.com/t5/New-to-Qlik-Analytics/Max-Date/td-p/1812770" target="_blank"&gt;https://community.qlik.com/t5/New-to-Qlik-Analytics/Max-Date/td-p/1812770&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.qlik.com/t5/App-Development/max-value-of-max-date/td-p/1821544" target="_blank"&gt;https://community.qlik.com/t5/App-Development/max-value-of-max-date/td-p/1821544&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;'Max" reference material:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/cloud-services/Subsystems/Hub/Content/Sense_Hub/Scripting/AggregationFunctions/max.htm" target="_blank"&gt;https://help.qlik.com/en-US/cloud-services/Subsystems/Hub/Content/Sense_Hub/Scripting/AggregationFunctions/max.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Kind regards...&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2024 22:49:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477815#M100407</guid>
      <dc:creator>Frank_S</dc:creator>
      <dc:date>2024-08-23T22:49:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477821#M100408</link>
      <description>&lt;P&gt;May be this expression in KPI, works for me -&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Max(Aggr(firstsortedvalue(Aggr(Max(Value),Date),-Date),Customer))&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Digvijay_Singh_1-1724472010153.png" style="width: 752px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170944i5DBC4602E716F5D5/image-dimensions/752x187?v=v2" width="752" height="187" role="button" title="Digvijay_Singh_1-1724472010153.png" alt="Digvijay_Singh_1-1724472010153.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2024 04:00:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477821#M100408</guid>
      <dc:creator>Digvijay_Singh</dc:creator>
      <dc:date>2024-08-24T04:00:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477822#M100409</link>
      <description>&lt;P&gt;Try this also, much simpler -&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Max(Total&amp;lt;Date&amp;gt; Value)&lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2024 04:02:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477822#M100409</guid>
      <dc:creator>Digvijay_Singh</dc:creator>
      <dc:date>2024-08-24T04:02:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477839#M100413</link>
      <description>&lt;P&gt;hello! Thanks very much for your help. I tried both formula you gave but they didn't work unfortunately &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;Attaching all the fields of data - could you help investigate?&lt;/P&gt;
&lt;P&gt;So essentially I want the latest Sales Revenue to be displayed in the KPI chart, driven by the customer name chosen in a filter. The 'latest' is determined by the Qlik Date field.&lt;/P&gt;
&lt;P&gt;-&amp;gt; Based on the data in attached file, I would want to show the 250 as my KPI if I select Whole Foods in my filter.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;what I tried was:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;1. create an expression to convert Qlik Date field to date format, and name this new field [Qlik Date in Date Format]&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikbbguser_0-1724506257480.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170945iAA40918F10191B02/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikbbguser_0-1724506257480.png" alt="qlikbbguser_0-1724506257480.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;2. Then i created another expression for Sales Revenue, and name this new field [Sales Revenue]:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikbbguser_1-1724506340936.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170946i23EB754CC31A3E9D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikbbguser_1-1724506340936.png" alt="qlikbbguser_1-1724506340936.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;3. Then I used your formula to calculate latest sales revenue:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlikbbguser_2-1724506425084.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170947iB41C708D4114C9EE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="qlikbbguser_2-1724506425084.png" alt="qlikbbguser_2-1724506425084.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My KPI chart shows '-' with customer filtered.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2024 13:36:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2477839#M100413</guid>
      <dc:creator>qlikbbguser</dc:creator>
      <dc:date>2024-08-24T13:36:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to retrieve the value from a field corresponding to the latest date</title>
      <link>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2478051#M100440</link>
      <description>&lt;P&gt;The problem appears to be with your data.&lt;/P&gt;
&lt;P&gt;1. ensure your source data is accurate (valid date and text fields in your excel file...general is used).&lt;/P&gt;
&lt;P&gt;2. you may not have correct associative source data. Source data may be in invalid format.&lt;/P&gt;
&lt;P&gt;3. when you have valid source data, ensure to concatenate your fields to create monthyear date values. (not shown in uploaded sample provided.&lt;/P&gt;
&lt;P&gt;The solution provided by &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/48860"&gt;@Digvijay_Singh&lt;/a&gt; does work if used with valid source data. His code is used in the app uploaded here.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Frank_S_0-1724686170051.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/170987i0B5616F73860D3AB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Frank_S_0-1724686170051.png" alt="Frank_S_0-1724686170051.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You may use the attached QVF to reverse engineer what was done.&lt;/P&gt;
&lt;P&gt;Should you need further assistance, you may wish to reach out to one of our trusted Qlik Partners or Qlik Professional services to troubleshoot your source data.&lt;/P&gt;
&lt;P&gt;Kind regards...well done &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/48860"&gt;@Digvijay_Singh&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2024 15:30:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-to-retrieve-the-value-from-a-field-corresponding-to-the/m-p/2478051#M100440</guid>
      <dc:creator>Frank_S</dc:creator>
      <dc:date>2024-08-26T15:30:27Z</dc:date>
    </item>
  </channel>
</rss>

