<?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 with selected values in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638392#M1088708</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok, if you want to ignore the user's selection in all date fields, like Year and Month, it's not enough to override just YearMonth, you would need to explicitely ignore &lt;EM style="text-decoration: underline;"&gt;all&lt;/EM&gt; &lt;EM&gt;the other date fields&lt;/EM&gt; (assuming Date, Month, Year for now) the user may select in when using the default set identifier:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;$&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Date=, Month= , Year=&lt;/STRONG&gt; &amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you only want to regard few fields the user may select, like Product, you can use set identfier 1 and pulling the users selection in:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;1&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Product = $::Product&lt;/STRONG&gt;&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or maybe&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;1&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Product = p()&lt;/STRONG&gt; &amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are differences in last two expressions in the way possible values for field Product (white elements in list box) are handled.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Jun 2014 06:59:17 GMT</pubDate>
    <dc:creator>swuehl</dc:creator>
    <dc:date>2014-06-04T06:59:17Z</dc:date>
    <item>
      <title>Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638387#M1088703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have three expression with set analysis to calculate a sales in month selected, budget in month selected and budget in a previous year for month selected, my formula to last expression is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({1&amp;lt;Field_1={'Criteria'}, YearMonth={$(vPrevMaxYearMonth)}&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"({1&amp;lt;" take all records...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, when my user select a product, my set expression doesn't work because pivot table shows all products.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can fix or improve my set expression if user needs select a year-month, product, business line, and another dimensions?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advanced.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 22:10:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638387#M1088703</guid>
      <dc:creator>javier_florian</dc:creator>
      <dc:date>2014-06-03T22:10:30Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638388#M1088704</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want the set expression to be sensitive to user selections, just overriding selections in fields Field_1 and YearMonth, try a set identifier $:&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;Sum({&lt;STRONG&gt;$&lt;/STRONG&gt;&amp;lt;Field_1={'Criteria'}, YearMonth={$(vPrevMaxYearMonth)}&amp;gt;} Value)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 22:38:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638388#M1088704</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2014-06-03T22:38:03Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638389#M1088705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Swuehl,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I use that formula, pivot table show:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="set analysis 2014-Jun.JPG.jpg" class="jive-image" src="/legacyfs/online/60055_set analysis 2014-Jun.JPG.jpg" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My formulas are:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sales 2014-Apr -&amp;gt; =-(Sum({$&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}&amp;gt;} (Value)))&lt;/P&gt;&lt;P&gt;Budget 2014-Apr -&amp;gt; =-(Sum({$&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}&amp;gt;} (Budget)))&lt;/P&gt;&lt;P&gt;Sales 2013-Apr -&amp;gt; =-Sum({1&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-JFlorian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 23:03:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638389#M1088705</guid>
      <dc:creator>javier_florian</dc:creator>
      <dc:date>2014-06-03T23:03:55Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638390#M1088706</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Any reason why you still keep the set identifer 1 in the last expression for Sales 2013-Apr?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 23:08:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638390#M1088706</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2014-06-03T23:08:06Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638391#M1088707</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If keep formula:&lt;/P&gt;&lt;P&gt;-Sum({$&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;And user select a year-month, I can get any value (result -&amp;gt; 0)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Jun 2014 23:17:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638391#M1088707</guid>
      <dc:creator>javier_florian</dc:creator>
      <dc:date>2014-06-03T23:17:19Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis with selected values</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638392#M1088708</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok, if you want to ignore the user's selection in all date fields, like Year and Month, it's not enough to override just YearMonth, you would need to explicitely ignore &lt;EM style="text-decoration: underline;"&gt;all&lt;/EM&gt; &lt;EM&gt;the other date fields&lt;/EM&gt; (assuming Date, Month, Year for now) the user may select in when using the default set identifier:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;$&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Date=, Month= , Year=&lt;/STRONG&gt; &amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you only want to regard few fields the user may select, like Product, you can use set identfier 1 and pulling the users selection in:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;1&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Product = $::Product&lt;/STRONG&gt;&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or maybe&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&lt;STRONG&gt;1&lt;/STRONG&gt;&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Field_1&lt;/SPAN&gt;={'&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Criteria&lt;/SPAN&gt;'}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;={$(vPrevMax&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;YearMonth&lt;/SPAN&gt;)}, &lt;STRONG&gt;Product = p()&lt;/STRONG&gt; &amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are differences in last two expressions in the way possible values for field Product (white elements in list box) are handled.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 06:59:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-with-selected-values/m-p/638392#M1088708</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2014-06-04T06:59:17Z</dc:date>
    </item>
  </channel>
</rss>

