<?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: Max Date in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291670#M1194792</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to know a lot of things - I do demographical analysis and transactional reporting and have 5 sheets of tables and charts based on the applications.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All I want is for any application to only be counted (loaded) once - and the LATEST must be used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So application 1234 might appear in the application extract for 12 June and be declined. Then it will appear again in the extract for 14 June and be approved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So they will have the same app number, the same LOG date, but different DECISION dates and different DECISION RESULTS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I do not want to know about the 12th june application, I want nothing to do with it, I only want the latest one as part of my data and calculations.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Jun 2011 07:56:24 GMT</pubDate>
    <dc:creator>gerhardl</dc:creator>
    <dc:date>2011-06-17T07:56:24Z</dc:date>
    <item>
      <title>Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291663#M1194785</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 have the following Expression for calculating Approval Rate of Applications:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;(count({$&amp;lt;[Decision Result]={'Approved'}&amp;gt;}[Appl No]))/count([Appl No])&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;The problem is that an application will sometimes be declined due to missing information, then approved at a later stage - with the same account number. But because this will be on different dates, QlikView counts this as separate applications. So if application A is declined on Monday and then approved on Tuesday, it will show the approval rate as 50%, but it should be 100% because it is one application.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I need to change the above expression to look at the field [Decision Date] and only include the LATEST decision date in the calculation. I guess I have to incorporate a maximum date function, but I dont know how - can someone please help??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gerhard &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 14:56:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291663#M1194785</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-15T14:56:32Z</dc:date>
    </item>
    <item>
      <title>Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291664#M1194786</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; hi&amp;nbsp; Gerhard,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what are you looking at rate of approval of applications or number of accounts that have been approved? Are you at all interested in point of time analysis, ie will you pull data with a date of Monday and count the application/account as not being approved or will the analysis always be as from now, ie as of today (or the last time you loaded the data) how many accounts have been approved / total.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the latter case in the script you should cretae an "account" table as opposed to the application table you have currently. In the account table you can establish a status with the latest (most recent) Decision Result. This will kmake your expressions simpler.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the former case you will have to look at building a master calendar and linking that up with your accounts.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 15:39:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291664#M1194786</guid>
      <dc:creator>pat_agen</dc:creator>
      <dc:date>2011-06-15T15:39:54Z</dc:date>
    </item>
    <item>
      <title>Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291665#M1194787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, a very simple solution is possible, if all applications can only be approved once:&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;count&lt;SPAN style="font-size: 8pt;"&gt;( {$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;status&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={Approved}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; ) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;distinct&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; ) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2011 16:39:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291665#M1194787</guid>
      <dc:creator />
      <dc:date>2011-06-15T16:39:25Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291666#M1194788</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;Sorry I thought that was working but something is not right. Please see the attached picture.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is now countin the correct number of applications, but when I need to see the number of DECLINED apps it counts all declined apps, even if the same app was later approved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When counting the declines, I need to only include the ones that were NOT later approved, so only the LATEST decision result must be used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;count({$&amp;lt;[Decision Result]={'Declined'}&amp;gt;} distinct [Appl No])&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;In the attached picture you can see there should only be 1 declined application, because one of the declines was later approved.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="5288" alt="QV Distinct.JPG" class="jive-image-thumbnail jive-image" height="232" src="https://community.qlik.com/legacyfs/online/5288_QV+Distinct.JPG" width="600" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 07:41:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291666#M1194788</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T07:41:56Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291667#M1194789</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can I add the distinct function to my script and only LOAD an application number once - and only load the latest one?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently the application data in my script looks like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;LOAD if([Company No]='SCSA','Shoe City SA', if([Company No]='HTSA','Hang Ten SA', if([Company No]='ASA','Ackermans SA', if([Company No]='ANA','Ackermans NAM' )))) as [Company No], &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Product No], &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Product Type], &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Appl No], &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(Date#( left( [Log Date],11), 'DD-MMM-YYYY')) as [Log Date], &lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(Date#( left( [Decision Date],11), 'DD-MMM-YYYY')) as [Decision Date],&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if([Decicion Result]='A',[Appl Score]) as [Appl Score Approved],&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if([Decicion Result]='D',[Appl Score]) as [Appl Score Declined],&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ETC.&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;FROM&lt;/STRONG&gt;&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;&lt;STRONG&gt;[.......\Application Extracts\Daily_ApplicationExtract_A_*.txt]&lt;/STRONG&gt;&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;&lt;STRONG&gt;(txt, codepage is 1252, embedded labels, delimiter is '~', no quotes)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;where ([Product No]&amp;gt;4);&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So if an [Appl No] appears more than once, I only want to load the one where the [Decision Date] is the latest.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;G&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 07:48:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291667#M1194789</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T07:48:57Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291668#M1194790</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well that depends on what you want to know. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want the number of application not approved you could do:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;( count( distinct application ) - count&lt;SPAN style="font-size: 8pt;"&gt;( {$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;status&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={Approved}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; ) ) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;distinct&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; ) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 07:49:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291668#M1194790</guid>
      <dc:creator />
      <dc:date>2011-06-17T07:49:02Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291669#M1194791</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry just saw in your post you dont want percentages anymore the number of applications approved and rejected. So maybe try:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Approved: count&lt;SPAN style="font-size: 8pt;"&gt;( {$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;status&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={Approved}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; ) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Declined: count( distinct application ) - count&lt;SPAN style="font-size: 8pt;"&gt;( {$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;status&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={Approved}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;application&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; )&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 07:55:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291669#M1194791</guid>
      <dc:creator />
      <dc:date>2011-06-17T07:55:01Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291670#M1194792</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to know a lot of things - I do demographical analysis and transactional reporting and have 5 sheets of tables and charts based on the applications.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All I want is for any application to only be counted (loaded) once - and the LATEST must be used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So application 1234 might appear in the application extract for 12 June and be declined. Then it will appear again in the extract for 14 June and be approved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So they will have the same app number, the same LOG date, but different DECISION dates and different DECISION RESULTS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I do not want to know about the 12th june application, I want nothing to do with it, I only want the latest one as part of my data and calculations.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 07:56:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291670#M1194792</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T07:56:24Z</dc:date>
    </item>
    <item>
      <title>Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291671#M1194793</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I concatenate the new application extract every day with the older ones.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So basically if an [Appl No] already exists, I want to overwrite it with the new day's data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 08:01:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291671#M1194793</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T08:01:53Z</dc:date>
    </item>
    <item>
      <title>Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291672#M1194794</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That fixes the number of declined applications. It now does not count the ones that were later approved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when I use [Decision Result] as a DIMENSION, it still returns the same, incorrect value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to do this to show the % of approved/declined next to the amount.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So my expression is just &lt;/P&gt;&lt;EM&gt;&lt;STRONG&gt;Count( distinct [Appl No]) &lt;/STRONG&gt;&lt;/EM&gt;with [Decision Result] as dimension.&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry for all the posts - I really appreciate your help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 08:09:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291672#M1194794</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T08:09:12Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291673#M1194795</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;Hi Gerhard,&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;Well first of all, if you really want to fetch the last [decision result] for each application, you can do something like:&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;sum( &lt;BR /&gt;if( &lt;BR /&gt;if (aggr( NODISTINCT max(date), application) = date, [decision result] ) = 'Approved', 1&lt;BR /&gt;))&lt;/DIV&gt;&lt;/SPAN&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;That will fetch the last decision result for any application.&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;Next problem is you want to use the [decision result] dimension. The problem is if you use that, the records selected for your calculations will be limited to your selection, so count( distinct application ) no longer gives you a count of all applications. You can ignore the selected dimension in your calculation with a set modifier &amp;lt;&amp;gt; as part of a set analysis {} :&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;count( {$&amp;lt;[decision result]=&amp;gt;} distinct application )&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 08:23:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291673#M1194795</guid>
      <dc:creator />
      <dc:date>2011-06-17T08:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291674#M1194796</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jeroen,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm really sorry, I am still figuring all of this stuff out, and I do not understand what you mean.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Where should I use the sum expression?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I REALLY want to do is change my load script to only import unique application number, and only the ones with the latest decision reslut.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That way I will not have to use any of these distinct expressions, I can just go on using my normal expression that I already have in place.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So load the same [Appl No] only once - always the one from the latest application extract or with the latest decision result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm so confused...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 08:36:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291674#M1194796</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T08:36:10Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291675#M1194797</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well that's the problem with getting your expressions accurate, they get harder to understand. That's why I prefer simple solutions like the first ones I posted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The first if() returns the value 1is the [decision result] equals approved. You can just Sum() these 1's.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to change your load script you could do something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LAST_APPLICATION:&lt;/P&gt;&lt;P&gt;LOAD application as LA_application, Max([decision date]) as LA_decision_date&lt;/P&gt;&lt;P&gt;RESIDENT APPLICATION&lt;/P&gt;&lt;P&gt;GROUP BY application;&lt;/P&gt;&lt;P&gt;INNER JOIN&lt;/P&gt;&lt;P&gt;LOAD application as LA_application, [decision date] as LA_decision_date, ... other fields&lt;/P&gt;&lt;P&gt;RESIDENT APPLICATION;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 08:51:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291675#M1194797</guid>
      <dc:creator />
      <dc:date>2011-06-17T08:51:48Z</dc:date>
    </item>
    <item>
      <title>Re: Max Date</title>
      <link>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291676#M1194798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wow - I really am starting to think I am too dumb for qlikview. Granted, I have never studied IT, I've never done any coding or SQL in my life, so this is all greek to me - I have to figure it out as I go.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know I've already asked too much of you - but I cannot seem to get it right. I have attached a word file with my load script. And I have highlighted the fields that are relevan to this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you could just edit the script so only the applications with the latest decision date is loaded, I would very very much appreciate it. I'm afraid I do not understand where in my script to type the above - I keep getting errors.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you so much for your patience.&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;G&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jun 2011 09:15:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Max-Date/m-p/291676#M1194798</guid>
      <dc:creator>gerhardl</dc:creator>
      <dc:date>2011-06-17T09:15:07Z</dc:date>
    </item>
  </channel>
</rss>

