<?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: First sorted value with aggr in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1982385#M81071</link>
    <description>&lt;P&gt;Hi Pierre, thanks for your help but this returns the lic_cod with the most glf_cod associated with it.&lt;/P&gt;
&lt;P&gt;I'm looking for the glf_cod where there are the most lic_cod (kind of the other way aroung from what you proposed).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Max(AGGR(Count(DISTINCT&amp;nbsp;lic_cod ),glf_cod )) would give me the highest count of lic_cod for the right glf_cod but I'm looking for the glf_cod, NOT the count associated with. FirstSortedValue would solve my problem but it keeps returning Null for a reason I don't get.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 19 Sep 2022 08:33:57 GMT</pubDate>
    <dc:creator>maxattar</dc:creator>
    <dc:date>2022-09-19T08:33:57Z</dc:date>
    <item>
      <title>First sorted value with aggr</title>
      <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981611#M81000</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trying to get the value glf_cod corresponding to the highest count of lic_cod for each glf_cod.&lt;/P&gt;
&lt;P&gt;I always get a null result when trying the following :&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FirstSortedValue(DISTINCT glf_cod,-Aggr(count(lic_cod),glf_cod))&lt;/P&gt;
&lt;P&gt;I have tried with and without Distinct and there is no tie for the first value.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does anyone have an idea of what I seem to be doing wrong please ?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Sep 2022 15:19:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981611#M81000</guid>
      <dc:creator>maxattar</dc:creator>
      <dc:date>2022-09-15T15:19:52Z</dc:date>
    </item>
    <item>
      <title>Re: First sorted value with aggr</title>
      <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981629#M81003</link>
      <description>&lt;P&gt;It may be this&lt;/P&gt;
&lt;P&gt;=FirstSortedValue(DISTINCT glf_cod,-Aggr(Count(lic_cod ),glf_cod),1)&lt;/P&gt;</description>
      <pubDate>Thu, 15 Sep 2022 15:51:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981629#M81003</guid>
      <dc:creator>BrunPierre</dc:creator>
      <dc:date>2022-09-15T15:51:02Z</dc:date>
    </item>
    <item>
      <title>Re: First sorted value with aggr</title>
      <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981638#M81005</link>
      <description>&lt;P&gt;Hi Peter,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for the answer but it still does not work :&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="maxattar_1-1663257807830.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/89212i45D3EFB3395612B5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="maxattar_1-1663257807830.png" alt="maxattar_1-1663257807830.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>Thu, 15 Sep 2022 16:03:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981638#M81005</guid>
      <dc:creator>maxattar</dc:creator>
      <dc:date>2022-09-15T16:03:38Z</dc:date>
    </item>
    <item>
      <title>Re: First sorted value with aggr</title>
      <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981648#M81006</link>
      <description>&lt;P&gt;=Max(AGGR(Count(DISTINCT glf_cod ),lic_cod ))&lt;/P&gt;</description>
      <pubDate>Thu, 15 Sep 2022 16:28:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1981648#M81006</guid>
      <dc:creator>BrunPierre</dc:creator>
      <dc:date>2022-09-15T16:28:43Z</dc:date>
    </item>
    <item>
      <title>Re: First sorted value with aggr</title>
      <link>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1982385#M81071</link>
      <description>&lt;P&gt;Hi Pierre, thanks for your help but this returns the lic_cod with the most glf_cod associated with it.&lt;/P&gt;
&lt;P&gt;I'm looking for the glf_cod where there are the most lic_cod (kind of the other way aroung from what you proposed).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Max(AGGR(Count(DISTINCT&amp;nbsp;lic_cod ),glf_cod )) would give me the highest count of lic_cod for the right glf_cod but I'm looking for the glf_cod, NOT the count associated with. FirstSortedValue would solve my problem but it keeps returning Null for a reason I don't get.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Sep 2022 08:33:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/First-sorted-value-with-aggr/m-p/1982385#M81071</guid>
      <dc:creator>maxattar</dc:creator>
      <dc:date>2022-09-19T08:33:57Z</dc:date>
    </item>
  </channel>
</rss>

