<?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 setanalysis with a dimension in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131547#M9276</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Hi everybody! &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;I'm trying to calculate the employee turnover. I need this data related to the same year period of last year. For example, currently (agoust 2018), I will need the employee turnover in the period jan-2017 - jul-2017. Next month I will need jan-2017 - ag-2017. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The formula I used for calculate the turnover of the hole last year (2017) year is:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Sum( {&amp;lt; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;[Leave Flag] = {1} &amp;gt;} [Worker Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; /&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; Count ( {&amp;lt;&amp;nbsp; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; &amp;gt;} [Worker Personal Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;This formula works properly. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The problem is that I need the same info, but not of the hole 2017, but just the same months that in the acual year (january-july). I've created a new dimension (Mes Acumulado Anual), which stablish that, if the month is lower or equal to the current month, then the value is 1. If the month is greater than the current month, then the value is 0. &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;I'll show you an example:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; background: #6690BC; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P align="center" style="margin-bottom: 1.5pt; text-align: center;"&gt;&lt;SPAN style="color: white; font-size: 10.0pt; font-family: 'Arial',sans-serif;"&gt;&lt;STRONG&gt;Month Number&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border: inset 1.0pt; border-left: none; background: #6690BC; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P align="center" style="margin-bottom: 1.5pt; text-align: center;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: white;"&gt;Mes Acumulado Anual&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;2&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;3&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;4&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;5&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;6&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;7&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;8&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;9&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;10&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;11&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;12&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;As you can check, the dimension works properly. I've tried to add this dimension to the set analysis of the turnover metric:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Sum( {&amp;lt; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, [Mes Acumulado Anual] = {1}, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; [Leave Flag] = {1} &amp;gt;} [Worker Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; /&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; Count ( {&amp;lt;&amp;nbsp; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, [Mes Acumulado Anual] = {1}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; &amp;gt;} [Worker Personal Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The problem is that the new argument does not change anything. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Could anybody help me?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Thank you!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 29 Aug 2018 11:00:40 GMT</pubDate>
    <dc:creator>anavalera</dc:creator>
    <dc:date>2018-08-29T11:00:40Z</dc:date>
    <item>
      <title>setanalysis with a dimension</title>
      <link>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131547#M9276</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Hi everybody! &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;I'm trying to calculate the employee turnover. I need this data related to the same year period of last year. For example, currently (agoust 2018), I will need the employee turnover in the period jan-2017 - jul-2017. Next month I will need jan-2017 - ag-2017. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The formula I used for calculate the turnover of the hole last year (2017) year is:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Sum( {&amp;lt; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;[Leave Flag] = {1} &amp;gt;} [Worker Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; /&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; Count ( {&amp;lt;&amp;nbsp; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'},&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; &amp;gt;} [Worker Personal Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;This formula works properly. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The problem is that I need the same info, but not of the hole 2017, but just the same months that in the acual year (january-july). I've created a new dimension (Mes Acumulado Anual), which stablish that, if the month is lower or equal to the current month, then the value is 1. If the month is greater than the current month, then the value is 0. &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;I'll show you an example:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; background: #6690BC; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P align="center" style="margin-bottom: 1.5pt; text-align: center;"&gt;&lt;SPAN style="color: white; font-size: 10.0pt; font-family: 'Arial',sans-serif;"&gt;&lt;STRONG&gt;Month Number&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border: inset 1.0pt; border-left: none; background: #6690BC; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P align="center" style="margin-bottom: 1.5pt; text-align: center;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: white;"&gt;Mes Acumulado Anual&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;2&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;3&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;4&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;5&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;6&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;7&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;1&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;8&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;9&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;10&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;11&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="border: inset 1.0pt; border-top: none; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;12&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;TD style="border-top: none; border-left: none; border-bottom: inset 1.0pt; border-right: inset 1.0pt; padding: 1.5pt 1.5pt 1.5pt 1.5pt;" valign="bottom"&gt;&lt;P style="margin-bottom: 1.5pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;0&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;As you can check, the dimension works properly. I've tried to add this dimension to the set analysis of the turnover metric:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Sum( {&amp;lt; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, [Mes Acumulado Anual] = {1}, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; [Leave Flag] = {1} &amp;gt;} [Worker Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; /&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; Count ( {&amp;lt;&amp;nbsp; [Calendar Type Code] = {1}, Year = {'$(vL.PeriodMaxYearM1)'}, [Mes Acumulado Anual] = {1}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt; &amp;gt;} [Worker Personal Counter] )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;The problem is that the new argument does not change anything. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Could anybody help me?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN-US" style="font-size: 10.0pt; font-family: 'Arial',sans-serif; color: #575757;"&gt;Thank you!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Aug 2018 11:00:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131547#M9276</guid>
      <dc:creator>anavalera</dc:creator>
      <dc:date>2018-08-29T11:00:40Z</dc:date>
    </item>
    <item>
      <title>Re: setanalysis with a dimension</title>
      <link>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131548#M9277</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dont quite understand what you need, can you rephrase your problem with an example?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Aug 2018 16:37:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131548#M9277</guid>
      <dc:creator>felipedl</dc:creator>
      <dc:date>2018-08-29T16:37:05Z</dc:date>
    </item>
    <item>
      <title>Re: setanalysis with a dimension</title>
      <link>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131549#M9278</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use a date table, and use them in your set analysis. Floor(yourDate), as YourDateField, then run it through YourDateTable in your script. It sounds like you need to use YTD-FLAG for current year. This will display the data up to your current date. For last years data use LYTD_FLAG. Modify/Create your own flags as needed. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let vStartDate=Floor(MakeDate(2016,1,1));&lt;/P&gt;&lt;P&gt;Let vEndDate=Floor(Today());&lt;/P&gt;&lt;P&gt;Let vDiff=vEndDate-vStartDate+1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;YourDateTable:&lt;/P&gt;&lt;P&gt;Qualify*;&lt;/P&gt;&lt;P&gt;Unqualify YourDateField;&lt;/P&gt;&lt;P&gt;Load *,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Date(MonthStart(YourDateField), 'YYYY-MM') As YearMonth,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Year &amp;amp; '-' &amp;amp; Quarter As YearQuarter,&lt;/P&gt;&lt;P&gt;&amp;nbsp; WeekYear &amp;amp; '-' &amp;amp; Num(Week, '00') As YearWeek;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; YourDateField,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Year(YourDateField) As Year,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Month(YourDateField) As Month,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Date(YourDateField) As Date,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Day(YourDateField) As Day,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Week(YourDateField) As Week,&lt;/P&gt;&lt;P&gt;&amp;nbsp; 'Q' &amp;amp; Ceil(Month(YourDateField)/3) As Quarter,&lt;/P&gt;&lt;P&gt;&amp;nbsp; WeekYear(YourDateField) As WeekYear,&lt;/P&gt;&lt;P&gt;&amp;nbsp; -Year2Date(YourDateField) As YTD_Flag,&lt;/P&gt;&lt;P&gt;&amp;nbsp; -Year2Date(YourDateField, -1) As LYTD_Flag,&lt;/P&gt;&lt;P&gt;&amp;nbsp; If( DayNumberOfQuarter(YourDateField) &amp;lt;= DayNumberOfQuarter(Today()), 1, 0) as IsInQTD,&lt;/P&gt;&lt;P&gt;&amp;nbsp; If( Day(YourDateField) &amp;lt;= Day(Today()), 1, 0) as IsInMTD,&lt;/P&gt;&lt;P&gt;&amp;nbsp; If( Month(YourDateField) = Month(Today()), 1, 0) as IsCurrentMonth,&lt;/P&gt;&lt;P&gt;&amp;nbsp; If( Month(AddMonths(YourDateField,1)) = Month(Today()), 1, 0) as IsLastMonth,&lt;/P&gt;&lt;P&gt;&amp;nbsp; If( DayNumberOfYear(YourDateField) &amp;lt;= DayNumberOfYear(Today()), 1, 0 ) as IsInYTD;&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; RecNo()-1+$(vStartDate) As YourDateField&lt;/P&gt;&lt;P&gt;AutoGenerate($(vDiff));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Derek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Aug 2018 19:17:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131549#M9278</guid>
      <dc:creator>Demlet</dc:creator>
      <dc:date>2018-08-29T19:17:29Z</dc:date>
    </item>
    <item>
      <title>Re: setanalysis with a dimension</title>
      <link>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131550#M9279</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Derek, &lt;/P&gt;&lt;P&gt;&lt;BR /&gt;We will try your suggestion.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Sep 2018 13:34:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/setanalysis-with-a-dimension/m-p/131550#M9279</guid>
      <dc:creator>anavalera</dc:creator>
      <dc:date>2018-09-04T13:34:46Z</dc:date>
    </item>
  </channel>
</rss>

