<?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 ignore all selections in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144922#M374762</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you both for the help.&amp;nbsp; I had tried those and thought they were wrong, but just figured out what the issue was.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm actually using: =Sum({$&amp;lt;FiscalYearMonthBound={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&amp;gt;} sold_cnt).&amp;nbsp; Copied from the wrong text object in my initial post.&amp;nbsp; The biggest difference is FiscalYearMonthBound was being used instead of FiscalYearMonth.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Users select date (ranges) using FiscalYearMonth, which was changing the sum because it isn't in the Set Analysis.&amp;nbsp; I reloaded the data with FiscalYearBound reanamed FiscalYearMonth and updated the Set Analysis, now it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had previously used $ and 1 but it just wouldn't work.&amp;nbsp; Thought I was losing my mind.&amp;nbsp; Happens every time - a problem in the load script causes me to spend way too much time troubleshooting/validating and it turns out to be something simple.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Again, I really, really appreciate the assistance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 13 May 2016 18:48:41 GMT</pubDate>
    <dc:creator>jcampbell474</dc:creator>
    <dc:date>2016-05-13T18:48:41Z</dc:date>
    <item>
      <title>Set Analysis ignore all selections</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144919#M374759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to create an expression for a chart (straight table) that displays a value for the previous year to date.&amp;nbsp; Since dates change, I have variables to handle them - the start and stop dates.&amp;nbsp; I've tried several different examples of set analysis to ignore selections, ($,1), but the sum always changes when I select a different year, month.&amp;nbsp; How can I make a variable calculate the previous YTD without changing based on what dates the user selects?&amp;nbsp; Essentially, 'Isolate' the field...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The date format is YearMonth (201505).&amp;nbsp; A variable contains the start (201501) and another contains the stop (201505).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Creating fields for the variables:&lt;/P&gt;&lt;P&gt;Left(max(FiscalYearMonth),4)&amp;amp;'01' as cFYMStart,&lt;/P&gt;&lt;P&gt;max(FiscalYearMonth) as cFYMStop,&lt;/P&gt;&lt;P&gt;Left(max(FiscalYearMonth),4)-1&amp;amp;'01' as pFYMStart,&lt;/P&gt;&lt;P&gt;Left(max(FiscalYearMonth),4)-1&amp;amp;'12' as pFYMStop,&lt;/P&gt;&lt;P&gt;max(FiscalYearMonth)-100 as pmaxFYM&lt;/P&gt;&lt;P&gt;Resident Fact;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Here are the variables:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Let vcFYMStart = num(peek('cFYMStart'));&lt;/P&gt;&lt;P&gt;Let vcFYMStop = num(peek('cFYMStop'));&lt;/P&gt;&lt;P&gt;Let vpFYMStart = num(peek('pFYMStart'));&lt;/P&gt;&lt;P&gt;Let vpFYMStop = num(peek('pFYMStop'));&lt;/P&gt;&lt;P&gt;Let vpmaxFYM = num(peek('pmaxFYM'));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is one example of the Set Analysis I've tried:&lt;/P&gt;&lt;P&gt;=Sum({$&amp;lt;FiscalYearMonth={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&amp;gt;} sold_cnt)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Additionally, I might add a couple of more views - Last 4-weeks (rolling), last 4-weeks previous year.&amp;nbsp; I'll need them to be static, too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to use Set Analysis so that I can calculate these numbers without them changing due to a different date being selected?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 May 2016 16:15:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144919#M374759</guid>
      <dc:creator>jcampbell474</dc:creator>
      <dc:date>2016-05-13T16:15:29Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis ignore all selections</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144920#M374760</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have you tried this already?&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; font-size: 13px;"&gt;&lt;STRONG&gt;=Sum({&lt;SPAN style="color: #ff0000;"&gt;1&lt;/SPAN&gt;&amp;lt;FiscalYearMonth={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&amp;gt;} sold_cnt)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or&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; font-size: 13px;"&gt;&lt;STRONG&gt;=Sum({$&amp;lt;FiscalYearMonth={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&lt;SPAN style="color: #ff0000;"&gt;, Year, Month&lt;/SPAN&gt;&amp;gt;} sold_cnt)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 May 2016 16:18:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144920#M374760</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-05-13T16:18:43Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis ignore all selections</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144921#M374761</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;This expression should ignore all selections and select FiscalYearMonth values that match the interval defined by your variables:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; =Sum({1&amp;lt;FiscalYearMonth={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&amp;gt;} sold_cnt)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 May 2016 16:20:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144921#M374761</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2016-05-13T16:20:06Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis ignore all selections</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144922#M374762</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you both for the help.&amp;nbsp; I had tried those and thought they were wrong, but just figured out what the issue was.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm actually using: =Sum({$&amp;lt;FiscalYearMonthBound={"&amp;gt;=$(vcFYMStart) &amp;lt;=$(vcFYMStop)"}&amp;gt;} sold_cnt).&amp;nbsp; Copied from the wrong text object in my initial post.&amp;nbsp; The biggest difference is FiscalYearMonthBound was being used instead of FiscalYearMonth.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Users select date (ranges) using FiscalYearMonth, which was changing the sum because it isn't in the Set Analysis.&amp;nbsp; I reloaded the data with FiscalYearBound reanamed FiscalYearMonth and updated the Set Analysis, now it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had previously used $ and 1 but it just wouldn't work.&amp;nbsp; Thought I was losing my mind.&amp;nbsp; Happens every time - a problem in the load script causes me to spend way too much time troubleshooting/validating and it turns out to be something simple.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Again, I really, really appreciate the assistance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 May 2016 18:48:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-ignore-all-selections/m-p/1144922#M374762</guid>
      <dc:creator>jcampbell474</dc:creator>
      <dc:date>2016-05-13T18:48:41Z</dc:date>
    </item>
  </channel>
</rss>

