<?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: Subtract two variables inside a set analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322595#M118806</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think it's much simpler than all that.&amp;nbsp; I think this would work, no variables required:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;{&amp;lt;CustomerID-=TheOtherCustomerIDField&amp;gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Assuming I got the syntax correct, that expression says "Give me the customer IDs that I selected but exclude the ones I selected in the other customer ID field."&amp;nbsp; However, I have no idea what you're doing with the only() or the sum() or what you're actually trying to accomplish, so merely plugging that set expression in to your expressions may not do what you want it to do.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 01 Aug 2011 23:22:26 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2011-08-01T23:22:26Z</dc:date>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322586#M118797</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;I'm trying to filter the content of a pivot table using a set analysis on a dimension, filtered by another dimension calculated on values obtained by the subtraction of two variables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;only({$&amp;lt;CustomeID={$(var_customed_id_selected)}-{$(var_customer_id_excluded)}&amp;gt;} Exhibition_edition)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inside my pivot table I'd like to view customer's exhibition participation, but only for those customers selected minus customer excluded.&lt;/P&gt;&lt;P&gt;The set of customers excluded is obtained through another customer table not linked in the data model.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The pivot table is not filtered..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any tips?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot,&lt;/P&gt;&lt;P&gt; Alessandro.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 12:53:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322586#M118797</guid>
      <dc:creator />
      <dc:date>2011-08-01T12:53:36Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322587#M118798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;this may help &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;only({$&amp;lt;CustomeID={$(var_customed_id_selected)}}&amp;gt;} Exhibition_edition)&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;only({$&amp;lt;CustomeID={{$(var_customer_id_excluded)}&amp;gt;} Exhibition_edition)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 12:57:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322587#M118798</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-08-01T12:57:23Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322588#M118799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;unfortunately the result is the same, the pivot table is not filtered by the expression.&lt;/P&gt;&lt;P&gt;For info, the two variables contain thow set of customer ID calculated though "concat" function.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't understand if it is the "only" function not used in a correct way or the subtraction not possible between the two variables.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:08:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322588#M118799</guid>
      <dc:creator />
      <dc:date>2011-08-01T13:08:30Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322589#M118800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sum({$&amp;lt;CustomeID={$(var_customed_id_selected)}}&amp;gt;}distinct Exhibition_edition)&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;CustomeID={{$(var_customer_id_excluded)}&amp;gt;} distinct Exhibition_edition)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:14:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322589#M118800</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-08-01T13:14:05Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322590#M118801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nothing yet &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:22:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322590#M118801</guid>
      <dc:creator />
      <dc:date>2011-08-01T13:22:50Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322591#M118802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; hei&lt;/P&gt;&lt;P&gt;what is the dimension of the pivot table &lt;/P&gt;&lt;P&gt;i thimk you can use the E() and P() function in set analsys&lt;/P&gt;&lt;P&gt;But i need better understanding of the pivot table structre&lt;/P&gt;&lt;P&gt;if you can post some sample data it would be great&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:32:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322591#M118802</guid>
      <dc:creator>lironbaram</dc:creator>
      <dc:date>2011-08-01T13:32:26Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322592#M118803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;there was syntax error in above.please try this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;CustomeID={$(var_customed_id_selected)}&amp;gt;}distinct Exhibition_edition)&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({$&amp;lt;CustomeID={$($(var_customer_id_excluded)}&amp;gt;}distinct Exhibition_edition)&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;thanks&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;﻿&lt;/SPAN&gt;Sunil Chauhan&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:34:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322592#M118803</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-08-01T13:34:08Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322593#M118804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I saw that and I've already wrote that in the correct way.&lt;/P&gt;&lt;P&gt;No success yet.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:37:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322593#M118804</guid>
      <dc:creator />
      <dc:date>2011-08-01T13:37:04Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322594#M118805</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well: the dimensions of the pivot table are the name of the customer, the name of the exhibition (concatenated with the edition) of the exhibition to which he participated, city and country of the customer.&lt;/P&gt;&lt;P&gt;Among the expressions, the calculation about exhibitor or visitor status of the customer, based on a certain set of rules on his past participations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The dimension on which I'd like to rule the set analysis is the exhibition edition to which the customer has participated.&lt;/P&gt;&lt;P&gt;The logic is the sequent:&lt;/P&gt;&lt;P&gt;- I set the first variable T1 with all customerdID acutally selected into the document, where CustomerID field is linked to all other data inside the data model;&lt;/P&gt;&lt;P&gt;- I set the second variable T2 with the CustomerID to be excluded: these ID belong to a different table not linked with the rest of data model.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, I want to filter on edition dimension, CustomerID that have participated to an exhibition (T1) minus CustomerID excluded by a list-box apart (T2) e subtract T1- T2 on the dimension.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 13:50:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322594#M118805</guid>
      <dc:creator />
      <dc:date>2011-08-01T13:50:08Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322595#M118806</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think it's much simpler than all that.&amp;nbsp; I think this would work, no variables required:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;{&amp;lt;CustomerID-=TheOtherCustomerIDField&amp;gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Assuming I got the syntax correct, that expression says "Give me the customer IDs that I selected but exclude the ones I selected in the other customer ID field."&amp;nbsp; However, I have no idea what you're doing with the only() or the sum() or what you're actually trying to accomplish, so merely plugging that set expression in to your expressions may not do what you want it to do.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 23:22:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322595#M118806</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-08-01T23:22:26Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322596#M118807</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;only({$&amp;lt;CustomeID={$(=$(var_customed_id_selected)}-{$(var_customer_id_excluded))}&amp;gt;} Exhibition_edition). try this code &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 03:53:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322596#M118807</guid>
      <dc:creator>perumal_41</dc:creator>
      <dc:date>2011-08-02T03:53:06Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322597#M118808</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; hei attach is an example&lt;/P&gt;&lt;P&gt;what i did is reloading the customer list twice&lt;/P&gt;&lt;P&gt;when you select customer in the list box on the right side&lt;/P&gt;&lt;P&gt;it will exclude then from the table &lt;/P&gt;&lt;P&gt;i am using the expression&lt;/P&gt;&lt;P&gt;{&amp;lt;CustomerID=-P(CustID2)&amp;gt;} which mean Exluding the Possible Client from CustID2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope its helps you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 07:59:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322597#M118808</guid>
      <dc:creator>lironbaram</dc:creator>
      <dc:date>2011-08-02T07:59:20Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322598#M118809</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you John, I tried your solution without success.&lt;/P&gt;&lt;P&gt;I know what I have to do but I've got no clear how to do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried all the solutions posted here but no result yet.&lt;/P&gt;&lt;P&gt;If I have an idea or an improvement I'll surely post it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 08:43:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322598#M118809</guid>
      <dc:creator />
      <dc:date>2011-08-02T08:43:02Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322599#M118810</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Maybe I'm near the solution but I've got a question: inside my pivot table, if my expression (I changed the "only" with a "count") returns two possible values, '0' and '1', and I want to show only the '1's , how can I do that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I checked the option "Suppresso zero-values" on Presentation folder of the expression with no result.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 14:50:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322599#M118810</guid>
      <dc:creator />
      <dc:date>2011-08-02T14:50:50Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322600#M118811</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Any suggestion about deleting rows from a pivot table in which the value of my expression return 0?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt; Alessandro.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Aug 2011 07:07:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322600#M118811</guid>
      <dc:creator />
      <dc:date>2011-08-03T07:07:19Z</dc:date>
    </item>
    <item>
      <title>Re: Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322601#M118812</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;I found the solution to my problem, in this expression:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(exhibition_name_excluded)&amp;gt;0 or GetSelectedCount(exhibition_edition_excluded)&amp;gt;0, &lt;/P&gt;&lt;P&gt;count({$&amp;lt;CustomerID={$(var_CustomerID_selected)}-{$(var_CustomerID_excluded)}&amp;gt;} Exhibition_edition),'2')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"exhibition_name_excluded" and "exhibition_edition_excluded" are the fields through which the user can choose the exhibition name or the exhibition edition to exclude. These fields are linked to the CustomerID_excluded inside the data model.&lt;/P&gt;&lt;P&gt;Once the exclusion is choosen, in my pivot table I show only the exhibiton edition (Exhibition_edition) filtered by set analysis {$&amp;lt;CustomerID={$(var_CustomerID_selected)}-{$(var_CustomerID_excluded)}&amp;gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inside the variable "var_CustomerID_selected" there are all the possible CustomerID (selected through CONCAT function) available in the document.&lt;/P&gt;&lt;P&gt;Inside the variable "var_CustomerID_excluded" there are all the excluded CustomerID (selected through CONCAT function), linked in the data model to the exhibitions exluded by the user.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The solution is good but with 600.000 CustomerID in my DB, the subtraction between the two variables and the calculation of the pivot table are too heavy for the server (Intel Xeon E7330@2.82 GHZ, 2 processors).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any suggestions about that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was thinking to eliminate the two variables and subtract the CustomeID and CustomerID_excluded directly inside the set analysis, something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(exhibition_name_excluded)&amp;gt;0 or GetSelectedCount(exhibition_edition_excluded)&amp;gt;0, &lt;/P&gt;&lt;P&gt;count({$&amp;lt;CustomerID={$(Chr(39) &amp;amp; concat(distinct Chr(39) &amp;amp; CustomerID, Chr(39) &amp;amp; ',' ) &amp;amp; Chr(39)) - {(Chr(39) &amp;amp; concat(distinct Chr(39) &amp;amp; CustomerID_escl, Chr(39) &amp;amp; ',' ) &amp;amp; Chr(39)) Exhibition_edition),'2')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The syntax doesn't work. Any suggestions?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 10:58:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322601#M118812</guid>
      <dc:creator />
      <dc:date>2011-08-04T10:58:16Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322602#M118813</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; prsesentation-&amp;gt; check on supress zero value&lt;/P&gt;&lt;P&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;/P&gt;&lt;P&gt;if( FieldName&amp;lt;&amp;gt;0,FieldName)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Aug 2011 11:54:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322602#M118813</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-08-04T11:54:08Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322603#M118814</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;the solution I described before works correctly but the performances decrease massively and the application is not usable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I thought the problem was storing a great number of customerID into the two variables and then subtract them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone can suggest me an alternative solution through which I can subtract from the possibile values (not only the selected ones) of an ID inside the document the values of another ID (in this case those selected)?&lt;BR /&gt;I'd need to filter the data linked to the ID resulting from the previous subtraction, inside a pivot table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 31 Aug 2011 13:20:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322603#M118814</guid>
      <dc:creator />
      <dc:date>2011-08-31T13:20:25Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322604#M118815</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Any suggestions?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Actually my set analysis is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(Id_Of_Exhibition_To_Exclude)&amp;gt;0 or GetSelectedCount(Id_Of_Edition_Of_Exhibition_To_Exclude)&amp;gt;0, &lt;/P&gt;&lt;P&gt;count({$&amp;lt;Customer_ID={$(VAR_Possible_Customer_ID)}-{$(VAR_CustomerID_To_Exclude)}&amp;gt;} EditionOfExhibition),'2')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The CustomerID to exclude are taken by a secondary table in the data model, not linked to the "cloud".&lt;/P&gt;&lt;P&gt;In this way, independently from the selection of the customerID inside the document, the user can select which Customer (Exhibition) to exclude, taken from another table and so not influenced by other selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It works but the subtraction between the two variables is too heavy as I sad in the previous posts.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm looking for an alternative set analysis with better performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Sep 2011 08:00:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322604#M118815</guid>
      <dc:creator />
      <dc:date>2011-09-02T08:00:07Z</dc:date>
    </item>
    <item>
      <title>Subtract two variables inside a set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322605#M118816</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;go to presentation and check supress zero values&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;/P&gt;&lt;P&gt;If(expression&amp;gt;0,expression)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where expression is formula written&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or clear mee if i am wrong &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;Sunil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Sep 2011 08:12:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtract-two-variables-inside-a-set-analysis/m-p/322605#M118816</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-09-02T08:12:22Z</dc:date>
    </item>
  </channel>
</rss>

