<?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: Count Distinct + Set Analysis and aggregation in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649770#M48466</link>
    <description>&lt;P&gt;In theory this is a correct calc:&amp;nbsp;&lt;SPAN&gt;COUNT(DISTINCT{&amp;lt;account_id = {"=SUM(sales)&amp;gt;0"}&amp;gt;}account_id&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;if you add it to the line chart with MonthYear as a first dim it should group measure values by the MonthYear.&lt;/P&gt;&lt;P&gt;After adding second dim, product, you should get multiple product lines grouped by the month.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you share the screen?&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 21 Nov 2019 18:28:31 GMT</pubDate>
    <dc:creator>y_grynechko</dc:creator>
    <dc:date>2019-11-21T18:28:31Z</dc:date>
    <item>
      <title>Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649754#M48461</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying to display a chart of the number of accounts purchasing a given over time. I have fields MonthYear, account_id, product, and sales, and want to display the count of account_id's with sales&amp;gt;0 in each month by product.&lt;/P&gt;&lt;P&gt;I'm struggling to determine the set analysis for my chart. measure-- ex: COUNT(DISTINCT{&amp;lt;account_id = {"=SUM(sales)&amp;gt;0"}&amp;gt;}account_id ) gives the accounts who have ever made a purchase, not just a purchase in the current month.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 04:03:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649754#M48461</guid>
      <dc:creator>nmarinelli</dc:creator>
      <dc:date>2024-11-16T04:03:14Z</dc:date>
    </item>
    <item>
      <title>Re: Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649758#M48463</link>
      <description>&lt;P&gt;Hey,&amp;nbsp;&lt;/P&gt;&lt;P&gt;are you trying to show in on the bar chart with MonthYear as a dimension?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 18:13:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649758#M48463</guid>
      <dc:creator>y_grynechko</dc:creator>
      <dc:date>2019-11-21T18:13:34Z</dc:date>
    </item>
    <item>
      <title>Re: Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649768#M48465</link>
      <description>&lt;P&gt;Yes a line chart with MonthYear and Product as dimensions&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 18:23:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649768#M48465</guid>
      <dc:creator>nmarinelli</dc:creator>
      <dc:date>2019-11-21T18:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649770#M48466</link>
      <description>&lt;P&gt;In theory this is a correct calc:&amp;nbsp;&lt;SPAN&gt;COUNT(DISTINCT{&amp;lt;account_id = {"=SUM(sales)&amp;gt;0"}&amp;gt;}account_id&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;if you add it to the line chart with MonthYear as a first dim it should group measure values by the MonthYear.&lt;/P&gt;&lt;P&gt;After adding second dim, product, you should get multiple product lines grouped by the month.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you share the screen?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 18:28:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649770#M48466</guid>
      <dc:creator>y_grynechko</dc:creator>
      <dc:date>2019-11-21T18:28:31Z</dc:date>
    </item>
    <item>
      <title>Re: Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649772#M48467</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Count(DISTINCT Aggr(If(Sum(sales) &amp;gt; 0, account_id), account_id, month))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 18:41:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649772#M48467</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-11-21T18:41:16Z</dc:date>
    </item>
    <item>
      <title>Re: Count Distinct + Set Analysis and aggregation</title>
      <link>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649796#M48468</link>
      <description>&lt;P&gt;It was working all along, the error was with my data model! Interesting that Sunny's response gives me a different result, but only ever so slightly. Will have to dive into the set analysis to understand why.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 19:40:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Count-Distinct-Set-Analysis-and-aggregation/m-p/1649796#M48468</guid>
      <dc:creator>nmarinelli</dc:creator>
      <dc:date>2019-11-21T19:40:03Z</dc:date>
    </item>
  </channel>
</rss>

