<?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 Outer set analysis - direct expression vs master measure item in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Outer-set-analysis-direct-expression-vs-master-measure-item/m-p/2083606#M88827</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I am encountering a strange behavior while using outer set analysis + master item measure compared to the direct writing of the same expression without using master measure.&lt;/P&gt;
&lt;P&gt;Here is the definition of my master measure item, called [Responses YTD] :&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;COUNT(distinct 
{&amp;lt;$(vYTDModifier), 
[Contact Survey invite status] = {'Responded'}, 
[Main contact survey response] = {'Yes'}, 
[Contact survey status 2] = {'5-Distributed'},
[Survey response submit date] = {"&amp;lt;=$(=Max(Date([Survey response closing date])))"}&amp;gt;} [Contact survey ID])&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The vYTDModifier variable contains the following code, and is intented to ignore user selections on calendar table, to force YTD :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Date=,Month=,MonthName=,Period=,Quarter=,[Seq_Périod]=,YearQuarter=,Year = {"$(=Max(Year))"}, MonthNum = {"&amp;gt;=1&amp;lt;=$(=Max(MonthNum))"}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now I get different result when I write this two expressions :&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Expression 1 (outer set + master measure)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{&amp;lt;[Survey type] = {'Field Service Intervention'}, [Sub-Region] = {'MEA'}&amp;gt;}[Responses YTD]&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Expression 2 (copy paste of the definition of the master measure in place of the master measure)&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{&amp;lt;[Survey type] = {'Field Service Intervention'}, [Sub-Region] = {'MEA'}&amp;gt;}
COUNT(distinct {&amp;lt;
$(vYTDModifier), 
[Contact Survey invite status] = {'Responded'}, [
Main contact survey response] = {'Yes'}, 
[Contact survey status 2] = {'5-Distributed'},
[Survey response submit date] = {"&amp;lt;=$(=Max(Date([Survey response closing date])))"}&amp;gt;} [Contact survey ID])&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In terms of data, we have 4 surveys corresponding to the definition in march, 1 in april, 0 in may.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When user selects march : results matches (4)&lt;BR /&gt;When user selects april : results matches (4+1 = 5)&lt;BR /&gt;When user selects may : expression 1 return 0, expression 2 return the correct response, 5.&lt;/P&gt;
&lt;P&gt;Did I miss something on the way the master measure items are working ? It feels like when no data is corresponding to the user selection + outer set, it is not working even if user selections should be ignored in the inner set.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We are running QlikSense on premise, with the version of february 2023 patch 5.&lt;/P&gt;</description>
    <pubDate>Wed, 14 Jun 2023 08:11:23 GMT</pubDate>
    <dc:creator>fabrice_lattern</dc:creator>
    <dc:date>2023-06-14T08:11:23Z</dc:date>
    <item>
      <title>Outer set analysis - direct expression vs master measure item</title>
      <link>https://community.qlik.com/t5/App-Development/Outer-set-analysis-direct-expression-vs-master-measure-item/m-p/2083606#M88827</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I am encountering a strange behavior while using outer set analysis + master item measure compared to the direct writing of the same expression without using master measure.&lt;/P&gt;
&lt;P&gt;Here is the definition of my master measure item, called [Responses YTD] :&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;COUNT(distinct 
{&amp;lt;$(vYTDModifier), 
[Contact Survey invite status] = {'Responded'}, 
[Main contact survey response] = {'Yes'}, 
[Contact survey status 2] = {'5-Distributed'},
[Survey response submit date] = {"&amp;lt;=$(=Max(Date([Survey response closing date])))"}&amp;gt;} [Contact survey ID])&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The vYTDModifier variable contains the following code, and is intented to ignore user selections on calendar table, to force YTD :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Date=,Month=,MonthName=,Period=,Quarter=,[Seq_Périod]=,YearQuarter=,Year = {"$(=Max(Year))"}, MonthNum = {"&amp;gt;=1&amp;lt;=$(=Max(MonthNum))"}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now I get different result when I write this two expressions :&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Expression 1 (outer set + master measure)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{&amp;lt;[Survey type] = {'Field Service Intervention'}, [Sub-Region] = {'MEA'}&amp;gt;}[Responses YTD]&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Expression 2 (copy paste of the definition of the master measure in place of the master measure)&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{&amp;lt;[Survey type] = {'Field Service Intervention'}, [Sub-Region] = {'MEA'}&amp;gt;}
COUNT(distinct {&amp;lt;
$(vYTDModifier), 
[Contact Survey invite status] = {'Responded'}, [
Main contact survey response] = {'Yes'}, 
[Contact survey status 2] = {'5-Distributed'},
[Survey response submit date] = {"&amp;lt;=$(=Max(Date([Survey response closing date])))"}&amp;gt;} [Contact survey ID])&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In terms of data, we have 4 surveys corresponding to the definition in march, 1 in april, 0 in may.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When user selects march : results matches (4)&lt;BR /&gt;When user selects april : results matches (4+1 = 5)&lt;BR /&gt;When user selects may : expression 1 return 0, expression 2 return the correct response, 5.&lt;/P&gt;
&lt;P&gt;Did I miss something on the way the master measure items are working ? It feels like when no data is corresponding to the user selection + outer set, it is not working even if user selections should be ignored in the inner set.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We are running QlikSense on premise, with the version of february 2023 patch 5.&lt;/P&gt;</description>
      <pubDate>Wed, 14 Jun 2023 08:11:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Outer-set-analysis-direct-expression-vs-master-measure-item/m-p/2083606#M88827</guid>
      <dc:creator>fabrice_lattern</dc:creator>
      <dc:date>2023-06-14T08:11:23Z</dc:date>
    </item>
  </channel>
</rss>

