<?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: FirstSortedValue from two sources in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725092#M1068287</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;4/24/2014 is the first mort_dt for Group_Cd 4120LR14 and so it brings back the correct Week 1 Mort %. When you select another mort_dt it changes the numbers to the mortality for that date. I have been trying to adjust the formula to take into account for this with no luck yet. I am very excited that we are this close to a resolution. Thank you again for your time and effort on this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 16 Sep 2014 12:34:32 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2014-09-16T12:34:32Z</dc:date>
    <item>
      <title>FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725068#M1068263</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a formula that uses the FirstSortedValue function that works fine as long as there is only one house that the iHeadMort comes from, but if it comes from two houses then I need some way to add the two amounts together.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=FirstSortedValue(iHeadMort,Mort_dt) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried something like this, but it did not work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=FirstSortedValue(SUM(iHeadMort),Mort_dt)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas will be greatly appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Sep 2014 20:35:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725068#M1068263</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-05T20:35:54Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725069#M1068264</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is this for a chart ?&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use the same chart aggregation syntax with firstsortedvalue. Assuming House is a field in the data model try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;FirstSortedValue(TOTAL &amp;lt;House&amp;gt; iHeadMort ,Mort_dt)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;it will bring the first value of iHeadMort within each grouping of House.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Sep 2014 20:49:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725069#M1068264</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-05T20:49:46Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725070#M1068265</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jonathan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is for a table. That sounds like it would work, but it didn't. I think its on the right track though.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Sep 2014 21:00:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725070#M1068265</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-05T21:00:51Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725071#M1068266</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it is for a back end table I would try a Group by.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;Suraj&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Sep 2014 21:05:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725071#M1068266</guid>
      <dc:creator />
      <dc:date>2014-09-05T21:05:07Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725072#M1068267</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK. Can you share a sample qvw ? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Sep 2014 21:47:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725072#M1068267</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-05T21:47:15Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725073#M1068268</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;Hi Bradley,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;You need something like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;=FirstSortedValue(iHeadMort, Aggr(SUM(Mort_dt),iHeadMort))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;FirstSortedValue() functions supports nested aggregation using the Aggr() function. Also, I'd recommend you to watch below video post on my blog.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;&lt;A class="unlinked" title="http://qlikshare.com/tag/firstsortedvalue/"&gt;http://qlikshare.com/tag/firstsortedvalue/&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;DV&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri,verdana,arial,sans-serif;"&gt;www.QlikShare.com&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 06 Sep 2014 11:53:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725073#M1068268</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2014-09-06T11:53:01Z</dc:date>
    </item>
    <item>
      <title>Re: Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725074#M1068269</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;IMG alt="Screenshot.png" class="jive-image" src="https://community.qlik.com/legacyfs/online/66255_Screenshot.png" style="width: 673px; height: 388px;" /&gt;Here is the table and a screenshot. I tried the Aggr formula from Deepak with no success. I think we are close to the solution and this is the last obstacle before this table can be published. Please help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 13:42:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725074#M1068269</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-08T13:42:36Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725075#M1068270</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bradley - can you tell me which field is your 'house' field ?&amp;nbsp; Also I assume the expression that is incorrect is 'Week 1 Mort %'&amp;nbsp; ?&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also the above approach isn't relevant because you need a combination of SUM and firstsortedvalue. The solution will likely be akin to what Deepak wrote below ...just need some more details of your model. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 14:23:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725075#M1068270</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-08T14:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725076#M1068271</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The field is house_# and yes Week 1 Mort % is the incorrect expression. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 14:28:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725076#M1068271</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-08T14:28:04Z</dc:date>
    </item>
    <item>
      <title>Re: Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725077#M1068272</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;Hi Bradley,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;I assume that you wanted to use this expression in the Pivot Table. If yes, have you tried the following expression:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;FirstSortedValue(House_#, Aggr(SUM(Mort_dt), House_#, sSvcman_cd, Project_#, Group_Name, Hatch_Date, Place_Date, Breed, Condition_Code, Breeder_Group))&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;PS: Add one more missing dimension in the above expression which is there in your chart [S E X]. If I include in the expression it requires moderation hence I'm writing this message seperately.&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;It works for me!&lt;BR /&gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;If you need to use the expression elsewhere please let me know which chart/sheet.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;DV&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;www.QlikShare.com&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 15:43:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725077#M1068272</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2014-09-08T15:43:55Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725078#M1068273</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Deepak,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So were you able to open the test file and use this expression to return the Week 1 Mort % for the group cd: 4120LR14 that was currently missing? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 16:47:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725078#M1068273</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-08T16:47:23Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725079#M1068274</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bradley,&amp;nbsp; I looked at your chart but based on your data model i see an issue with the following description:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;EM&gt;"I have a formula that uses the FirstSortedValue function that works fine as long as there is only one house that the iHeadMort comes from, but if it comes from two houses then I need some way to add the two amounts together."&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;iHeadMort comes from the GroupMortality table and the numbers are associateed to the rest of the data model on 'Group Key ID' . &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;'Group Key ID'&amp;nbsp; will associate to multiple values of&amp;nbsp; 'Breeder Group' through a linked table .From there, each combination will associated to one or more records in the 'Group Placements' table.&amp;nbsp; House_# is in this Group placements table and there may be several records for each house and also several houses.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;So basically iHeadMort seems to be reported at a higher level than House_# in a separate table, so if I have an iHeadMort value of 100 ,&amp;nbsp; i'm not sure i understand how to come up with broken down value for each house. Even if you are only asking for the oldest value based on Mort_dt , that single record from the GroupMortality table may associate to&amp;nbsp; multiple house_#'s from the 'Group Placements' table&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Its sort of like reporting the population of a continent , and then asking qlik for an expression that calculates the country... you can't necause the data doesn't have the populations reported at the country level&amp;nbsp; ...and so the question only works if there is only 1 country in a&amp;nbsp; continent.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;I'm not sure what your source data says but you may need to create a data model that has both house and iHeadMort in the same table or at least iHeadMort reported at the same or lower level of granularity as 'house_#'. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Am i way off ?&amp;nbsp; &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&amp;nbsp; i spent a bit of time looking at it and i'm a bit cross eyed.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Sep 2014 20:26:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725079#M1068274</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-08T20:26:12Z</dc:date>
    </item>
    <item>
      <title>Re: Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725080#M1068275</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;I'm getting results for [Week 1 Mort%]. But I'm not sure if they are expected results. See the attached screenshot and following expression. I can see the values for&lt;SPAN style="color: #800000;"&gt;&lt;STRONG&gt;&lt;EM&gt; [Group Cd]&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt; field, however for the rows &lt;SPAN style="color: #800000;"&gt;&lt;STRONG&gt;&lt;EM&gt;4120LR14&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt; you're getting same numbers even after aggregating the data hence you'll see two NULL values. I've checked these values and both of them have same dimension values and same expression result values, hence &lt;STRONG&gt;&lt;EM&gt;FirstSortedValue()&lt;/EM&gt;&lt;/STRONG&gt; with &lt;STRONG&gt;&lt;EM&gt;Aggr()&lt;/EM&gt;&lt;/STRONG&gt; function still returns NULL values for these two records. But rest everything seems to be working. Let me know if this what you need?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-family: calibri, verdana, arial, sans-serif; text-decoration: underline;"&gt;&lt;STRONG&gt;&lt;EM&gt;Expression:&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080; font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;FirstSortedValue(House_#, Aggr( SUM(Mort_dt), House_#, sSvcman_cd, Project_#, Group_Name, Hatch_Date, Place_Date, Breed, Sex, Condition_Code, Breeder_Group))&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080; font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;EM&gt;&lt;STRONG&gt;/ &lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080; font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;STRONG&gt;&lt;EM&gt;SUM(total &amp;lt;House_#, sSvcman_cd, Project_#, Group_Name, Hatch_Date, Place_Date, Breed, Sex, Condition_Code, Breeder_Group&amp;gt; Head_Start)&lt;/EM&gt;&lt;/STRONG&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-family: calibri, verdana, arial, sans-serif;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;DV&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;www.QlikShare.com&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 08:40:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725080#M1068275</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2014-09-09T08:40:00Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725081#M1068276</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks guys for your help. I hope to be just like you when I grow up &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;. Thank you Jonathan for your time spent digging into the root of the problem, and thank you Deppak for never giving up on the correct answer. I will look at another way to load the information if this becomes a big problem. For now it seems that this problem is not correctable with the current state of the data. Again, I thank you for your time and wisdom on this problem. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 12:45:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725081#M1068276</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-09T12:45:04Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725082#M1068277</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Brad.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 12:51:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725082#M1068277</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-09T12:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725083#M1068278</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;That's great Brad. In fact, I like working on these kind of issues. I wish you good luck!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;Jonathan - You're one of few people on community, who cares to give not just the correct answer but also helpful &amp;amp; friendly response with clear explanation instead of just aiming at the points. Thank you for your all contributions on the community.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;DV&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: calibri, verdana, arial, sans-serif;"&gt;www.QlikShare.com&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 13:10:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725083#M1068278</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2014-09-09T13:10:30Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725084#M1068279</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;cheers deepak!&amp;nbsp; i can see Bradley put together some effort to create a sample so the least i can do is the same.&amp;nbsp; i thought i knew a fair amount of QV prior to 'getting active' on community but the range of solutions from yourself and others that i see on this forum honestly has me back to learning things every day which i did not expect... but that is the nature of qlikview so i should not be surprised &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 13:29:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725084#M1068279</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-09T13:29:08Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725085#M1068280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just spoke with one of my coworkers here and showed them Jonathan's explanation and he said that I am not looking to group from House_# that is in the placement table, but from MortHouse that comes from the mortality table. would this help make a difference in the levels Jonathan mentioned?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 13:33:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725085#M1068280</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-09T13:33:49Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725086#M1068281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It definitely should. Thats the same table where the other 2 fields come from so we should be good on the granularity...&amp;nbsp; stay tuned &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Sep 2014 13:38:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725086#M1068281</guid>
      <dc:creator>JonnyPoole</dc:creator>
      <dc:date>2014-09-09T13:38:49Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue from two sources</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725087#M1068282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;IMG alt="Screenshot.png" class="jive-image" src="https://community.qlik.com/legacyfs/online/66468_Screenshot.png" style="width: 664px; height: 388px;" /&gt;&lt;/P&gt;&lt;P&gt;So what I need now is some way to add the amount from MortHouse 1 &amp;amp; 2 together but still only retrieve the FirstSortedValue for each. Do I need some sort of Aggr function as Deepak mentioned earlier, or is there another way to total these? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Sep 2014 13:30:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-from-two-sources/m-p/725087#M1068282</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-10T13:30:30Z</dc:date>
    </item>
  </channel>
</rss>

