<?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: Set Analysis Intersection help in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847468#M297473</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sergey -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I actually got it to work by cheating a little. Instead of a line chart, I used a bar chart with expressions for 8 weeks. (We have a field for relative weeks&amp;nbsp; built into the master calendar so it will roll) Then uses Manish's formula.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="line.PNG" class="jive-image image-1" height="193" src="https://community.qlik.com/legacyfs/online/82831_line.PNG" style="height: 193.149012567325px; width: 328px;" width="328" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 Apr 2015 17:45:06 GMT</pubDate>
    <dc:creator>mikecrengland</dc:creator>
    <dc:date>2015-04-02T17:45:06Z</dc:date>
    <item>
      <title>Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847459#M297464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a situation where we have two payroll systems that an employee might be paid from. It's considered an exception if the employee is paid out of both systems during the same week. The payroll team has asked for a trending chart of the number of exceptions per week. The data has a flag (1 or 2) that indicates which system paid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="rsflag.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/82824_rsflag.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basically, what I want to do is to count employees that have both flags in a week. The dimension is WeekStart and the expression is (I've tried with and with out quotes around the numbers):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Count({&amp;lt;Payroll.RSFlag = {1}&amp;gt; * &amp;lt;Payroll.RSFlag = {2}&amp;gt;} Distinct Employee)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shouldn't this give me a count of employees with both flags, but not one or the other? My chart gives me 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="line.PNG" class="jive-image image-2" height="166" src="https://community.qlik.com/legacyfs/online/82825_line.PNG" style="height: 165.275109170306px; width: 249px;" width="249" /&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 15:53:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847459#M297464</guid>
      <dc:creator>mikecrengland</dc:creator>
      <dc:date>2015-04-02T15:53:46Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847460#M297465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Mike!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you try expression below?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sergey.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count(aggr(if(min(Payroll.RSFlag)&amp;lt;&amp;gt;max(Payroll.RSFlag),Employee),Call.WeekStartMon))&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Безымянный.png" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/82816_Безымянный.png" style="height: 263px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:32:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847460#M297465</guid>
      <dc:creator>pokassov</dc:creator>
      <dc:date>2015-04-02T16:32:45Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847461#M297466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SUM(Aggr(COUNT({&amp;lt;Payroll.RSFlag = {1}, Employee = P({&amp;lt;Payroll.RSFlag= {2}&amp;gt;}Employee)&amp;gt;}DISTINCT Employee),Employee))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:33:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847461#M297466</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2015-04-02T16:33:07Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847462#M297467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, Manish!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have checked your expression with my test example.&lt;/P&gt;&lt;P&gt;It looks like there is a mistake...&lt;/P&gt;&lt;P&gt;Could you check?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;t1:&lt;/P&gt;&lt;P&gt;LOAD * Inline [&lt;/P&gt;&lt;P&gt;Employee, Call.WeekStartMon, Payroll.RSFlag&lt;/P&gt;&lt;P&gt;ADALEE, 2015-03-09, 1&lt;/P&gt;&lt;P&gt;ADALEE, 2015-03-09, 2&lt;/P&gt;&lt;P&gt;ADALEE, 2015-03-16, 1&lt;/P&gt;&lt;P&gt;ADALEE, 2015-03-23, 1&lt;/P&gt;&lt;P&gt;BBBAAA, 2015-03-23, 2&lt;/P&gt;&lt;P&gt;BBBAAA, 2015-03-30, 1&lt;/P&gt;&lt;P&gt;BBBAAA, 2015-03-30, 2&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="82832" alt="Безымянный3.png" class="jive-image image-1" height="243" src="https://community.qlik.com/legacyfs/online/82832_Безымянный3.png" style="height: 242.425287356322px; width: 393px;" width="393" /&gt;&lt;/P&gt;&lt;P&gt;2015-03-23 - your expression shows 1, meanwhile the right answer is 0 because there are different employees in this week. not the same.&lt;/P&gt;&lt;P&gt;Sergey&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:44:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847462#M297467</guid>
      <dc:creator>pokassov</dc:creator>
      <dc:date>2015-04-02T16:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847463#M297468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I haven't tested.. but if it is not working, you can try below option...&lt;/P&gt;&lt;P&gt;SUM(IF(Aggr(Count(DISTINCT Payroll.RSFlag),Employee,Call.WeekStartMon)&amp;gt;1,1))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:49:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847463#M297468</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2015-04-02T16:49:33Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847464#M297469</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sergey,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately, this returned 0, but I'm going to keep trying to tweak it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:49:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847464#M297469</guid>
      <dc:creator>mikecrengland</dc:creator>
      <dc:date>2015-04-02T16:49:34Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847465#M297470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, Manish! This looks like it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 16:50:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847465#M297470</guid>
      <dc:creator>mikecrengland</dc:creator>
      <dc:date>2015-04-02T16:50:23Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847466#M297471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, this works for one week, but if I take off the date filter, the line chart explodes and shows 20x the correct number. An example is the week of&amp;nbsp; 2/2 gives me 42, but if I unfilter the date, that same week shows 465.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I vaguely remember something about indirect set analysis and that the p/e part is calculated at the chart level, not the row level so the calculation is based on any that are both 1 and 2, not just during the week dimension. Do you know if that's true?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 17:17:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847466#M297471</guid>
      <dc:creator>mikecrengland</dc:creator>
      <dc:date>2015-04-02T17:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847467#M297472</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mike, can you attach your model with some example data?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 17:23:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847467#M297472</guid>
      <dc:creator>pokassov</dc:creator>
      <dc:date>2015-04-02T17:23:47Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis Intersection help</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847468#M297473</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sergey -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I actually got it to work by cheating a little. Instead of a line chart, I used a bar chart with expressions for 8 weeks. (We have a field for relative weeks&amp;nbsp; built into the master calendar so it will roll) Then uses Manish's formula.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="line.PNG" class="jive-image image-1" height="193" src="https://community.qlik.com/legacyfs/online/82831_line.PNG" style="height: 193.149012567325px; width: 328px;" width="328" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Apr 2015 17:45:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-Intersection-help/m-p/847468#M297473</guid>
      <dc:creator>mikecrengland</dc:creator>
      <dc:date>2015-04-02T17:45:06Z</dc:date>
    </item>
  </channel>
</rss>

