<?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 comparing two fields in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797667#M281736</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try like this&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({&amp;lt;Master_WeekNum = {$(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;=Concat(DISTINCT Quota_WeekNum, ',')&lt;/SPAN&gt;)}&amp;gt;}[Allocation %])&lt;/SPAN&gt;&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;OR&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Sum(If(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Master_WeekNum &lt;/SPAN&gt; = &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Quota_WeekNum&lt;/SPAN&gt;, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;[Allocation %]&lt;/SPAN&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;"&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;"&gt;Or in script simply join both the tables.&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;"&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;"&gt;Hope this helps you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Regars,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Jagan.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Nov 2014 15:18:45 GMT</pubDate>
    <dc:creator>jagan</dc:creator>
    <dc:date>2014-11-21T15:18:45Z</dc:date>
    <item>
      <title>Set analysis comparing two fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797664#M281733</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Howdy, can someone help me get the third column in the left table working correctly...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to have set analysis to ...but its not working&lt;/P&gt;&lt;P&gt;Sum({&amp;lt;Master_WeekNum = {Quota_WeekNum}&amp;gt;}[Allocation %])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to bring over the allocation % from the table on the right...to match the same "Master_WeekNum" for the table on the left.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Much thanks!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-David&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Quota vs. week num.PNG.png" class="jive-image" src="/legacyfs/online/71834_Quota vs. week num.PNG.png" style="width: 620px; height: 626px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Nov 2014 14:52:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797664#M281733</guid>
      <dc:creator />
      <dc:date>2014-11-21T14:52:25Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis comparing two fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797665#M281734</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Probably best to join the 2 tables in the load script, the you just need to put the dimension and 2 expressions into your chart it will associate and work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hard to give precise instructions.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Share a picture of your data model and maybe even the text of your load script and I am sure someone will assist.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Nov 2014 15:07:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797665#M281734</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-11-21T15:07:24Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis comparing two fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797666#M281735</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I was trying to keep them seperate in the model...is it possible to write the set analysis to simply compare the week number dimensions?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Nov 2014 15:13:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797666#M281735</guid>
      <dc:creator />
      <dc:date>2014-11-21T15:13:37Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis comparing two fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797667#M281736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try like this&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({&amp;lt;Master_WeekNum = {$(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;=Concat(DISTINCT Quota_WeekNum, ',')&lt;/SPAN&gt;)}&amp;gt;}[Allocation %])&lt;/SPAN&gt;&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;OR&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Sum(If(&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Master_WeekNum &lt;/SPAN&gt; = &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Quota_WeekNum&lt;/SPAN&gt;, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;[Allocation %]&lt;/SPAN&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;"&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;"&gt;Or in script simply join both the tables.&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;"&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;"&gt;Hope this helps you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Regars,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Jagan.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Nov 2014 15:18:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797667#M281736</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2014-11-21T15:18:45Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis comparing two fields</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797668#M281737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I know it is a long time ago this question was posed - but for the benefit of those that might search this up:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;STRONG style="font-size: 12pt;"&gt;1.&lt;/STRONG&gt; Your Set Expression is not entirely correct. To be able to compare two fields the second field &lt;SPAN style="text-decoration: underline;"&gt;must not be enclosed in curly braces&lt;/SPAN&gt;&lt;BR /&gt; (curly-brackets) since the field itself constitutes a set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;So the expression should look like this:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG style=": ; font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&lt;BR /&gt;Sum( { &amp;lt;Master_WeekNum=Quota_WeekNum&amp;gt; } [Allocation %] )&lt;BR /&gt;&lt;BR /&gt;&lt;/STRONG&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;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG style="font-size: 12pt;"&gt;2.&lt;/STRONG&gt; To be able to do a comparision you &lt;SPAN style="text-decoration: underline;"&gt;have to have one or more values selected&lt;/SPAN&gt; in the second field (Quota_WeekNum) or the comparision will not be done. Possible values will not be included in the comparison - only selected values. That is according to the help in QlikView that states (the underscores and italics are mine):&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;H3 style="padding-left: 30px;"&gt;&lt;SPAN style="color: #008000;"&gt;Based on another field&lt;/SPAN&gt;&lt;/H3&gt;&lt;P style="padding-left: 30px;"&gt;A simple case is a selection based on the &lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;&lt;EM&gt;selected values&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt; of another field, for example &amp;lt;OrderDate = DeliveryDate&amp;gt;. This modifier will take &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;the selected values&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt; from &lt;SPAN class="Bold"&gt;DeliveryDate&lt;/SPAN&gt; and apply those &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;as a selection on &lt;SPAN class="Bold"&gt;OrderDate&lt;/SPAN&gt;.&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt; If there are many distinct values – more than a couple of hundred – then this operation is CPU intense and should be avoided.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 26 Jul 2015 10:47:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-comparing-two-fields/m-p/797668#M281737</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2015-07-26T10:47:09Z</dc:date>
    </item>
  </channel>
</rss>

