<?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 Set Analysis with 3 Fields in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192633#M501221</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;PeriodID ={'3'}, PeriodDesc = &amp;gt;} SalesUnit)&lt;/P&gt;&lt;P&gt;i.e. you could either set PeriodDesc to be ignored or you could also set it to LastWeek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 19 Nov 2010 21:31:38 GMT</pubDate>
    <dc:creator>charlotte_qvw</dc:creator>
    <dc:date>2010-11-19T21:31:38Z</dc:date>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192621#M501204</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have three fields: Units, Period, Customer&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to use Set Analysis to create a set of sum(Units) where Period = 3 and the Current customer is selected (this value is at least one selected).&lt;/P&gt;&lt;P&gt;I need to use the whole available set not just current because the user can change the Period selection. What is the best way to do this? I have tried&lt;/P&gt;&lt;P&gt;sum({1&amp;lt;Customer=, Period ={'3'}&amp;gt;} Units) and many other possibilities but I still can't get it to function properly. Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Nov 2010 07:24:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192621#M501204</guid>
      <dc:creator />
      <dc:date>2010-11-18T07:24:03Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192622#M501205</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Michael,&lt;/P&gt;&lt;P&gt;I'm afraid I'm missing something. Your code above seems fine, since you are using "1" (all possible values), "Customer=" (Ignoring user's selection in field Customer) and Period = {3} (selecting value "3" in field Period). Which behavior is expected? If the user is allowed to change the period, the expression above should work anyway.&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Nov 2010 08:33:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192622#M501205</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2010-11-18T08:33:30Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192623#M501206</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It appears that it is returning the sum for ALL Customers, where I need only the sum for the current selected customer. How do I make it do that?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Nov 2010 15:16:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192623#M501206</guid>
      <dc:creator />
      <dc:date>2010-11-18T15:16:37Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192624#M501207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello MIchael,&lt;/P&gt;&lt;P&gt;If you want the user's selection in Customer&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;sum({1&amp;lt; Period = {'3'} &amp;gt;} Units)&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;In your example above you were ignoring users's selection for field Customer.&lt;/P&gt;&lt;P&gt;Hope that helps&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Nov 2010 16:17:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192624#M501207</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2010-11-18T16:17:27Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192625#M501208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So you want to ignore all selections EXCEPT for customer, and you specifically want period 3? I believe this:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({1&amp;lt;Customer=P(),Period={'3'}&amp;gt;} Units)&lt;/P&gt;&lt;P&gt;However, if ALL you wanted to ignore was the period, then just override the period:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({&amp;lt;Period={'3'}&amp;gt;} Units)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 01:22:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192625#M501208</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-11-19T01:22:50Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192626#M501209</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you both but I'm still having trouble. This is exactly what I want: "ALL you wanted to ignore was the period, then just override the period:", however, when I use this formula and change the time period, the value goes to Zero unless I'm selected into Period 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 01:38:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192626#M501209</guid>
      <dc:creator />
      <dc:date>2010-11-19T01:38:53Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192627#M501210</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If I got the requirements right:&lt;BR /&gt;sum({$&amp;lt;Period ={'3'}&amp;gt;} Units)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 02:57:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192627#M501210</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2010-11-19T02:57:33Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192628#M501211</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have attached a .qvw to better help explain (the suggested answers are still not working). Thanks for your help everyone&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 04:28:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192628#M501211</guid>
      <dc:creator />
      <dc:date>2010-11-19T04:28:08Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192629#M501214</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is easiest to reproduce the problem by selecting a PeriodDesc in the multibox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example: &lt;B&gt;Blue, Last Month&lt;/B&gt; should yield 30, but the set analysis is returning 0.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 04:34:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192629#M501214</guid>
      <dc:creator />
      <dc:date>2010-11-19T04:34:57Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192630#M501216</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You told us your field names were Period and Units. So I gave you this:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({&amp;lt;Period={'3'}&amp;gt;} Units)&lt;/P&gt;&lt;P&gt;And Michael gave you an equivalent (the $ is optional):&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({$&amp;lt;Period ={'3'}&amp;gt;} Units)&lt;/P&gt;&lt;P&gt;In the example you posted, the field names are instead PeriodID and SalesUnit. You need to use your &lt;EM&gt;real&lt;/EM&gt; field names in the expression, not the incorrect field names that you told us:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({&amp;lt;PeriodID={'3'}&amp;gt;} SalesUnit)&lt;/P&gt;&lt;P&gt;That gives the results you want.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 18:06:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192630#M501216</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-11-19T18:06:55Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192631#M501218</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;PeriodID ={'3'}&amp;gt;} SalesUnit)&lt;/P&gt;&lt;DIV&gt;^^ This is in the application I attached earlier in the main text box, center screen. I created this after my initial post so sorry if the naming threw you off.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Open the application and select Blue Customer and Last Month. Based on your equation, I should see "30" units, but I'm getting "0", no? What am I doing wrong?&lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 18:25:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192631#M501218</guid>
      <dc:creator />
      <dc:date>2010-11-19T18:25:48Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192632#M501220</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Edit: Wait, OK, I see the 0 now, when you DO copy in the expression and do the selections you say, THEN it gets 0. It gets 0 because you are overriding the PeriodID, but making a selection in PeriodDesc. Since these fields are, I gather, the same thing, you ALSO need to tell it to ignore PeriodDesc.&lt;/P&gt;&lt;P&gt;sum({&amp;lt;PeriodID ={'3'},PeriodDesc=&amp;gt;} SalesUnit)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 19:57:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192632#M501220</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-11-19T19:57:05Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192633#M501221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;PeriodID ={'3'}, PeriodDesc = &amp;gt;} SalesUnit)&lt;/P&gt;&lt;P&gt;i.e. you could either set PeriodDesc to be ignored or you could also set it to LastWeek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 21:31:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192633#M501221</guid>
      <dc:creator>charlotte_qvw</dc:creator>
      <dc:date>2010-11-19T21:31:38Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192634#M501222</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The dollar sign is optional. I prefer to not include it since $ is also used in dollar sign expansion and to identify parameters, but I may be in the minority.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 21:53:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192634#M501222</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-11-19T21:53:17Z</dc:date>
    </item>
    <item>
      <title>Set Analysis with 3 Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192635#M501223</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you everyone - sorry if I confused anyone. Charlotte.qvw's answer fixed the problem&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Nov 2010 23:05:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-with-3-Fields/m-p/192635#M501223</guid>
      <dc:creator />
      <dc:date>2010-11-19T23:05:03Z</dc:date>
    </item>
  </channel>
</rss>

