<?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 How to write an expression to show a 'complement' table (i.e. all values not in another table for a certain field)? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-write-an-expression-to-show-a-complement-table-i-e-all/m-p/610223#M225210</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;I want to have 2 straight tables:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Table 1:&lt;/P&gt;&lt;P&gt;Contains 1 field (Product_ID), and 1 expression based on Sales (e.g. sum(Sales)). My expression is actually much more complicated than this, though. Based on my selections of Product_ID, certain records of Product_ID (and corresponding Sales expression value) appear in the table (dependent on my expression).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I want to create a second table so that it holds all &lt;STRONG&gt;other&lt;/STRONG&gt; records &lt;STRONG&gt;not&lt;/STRONG&gt; shown in Table 1. Is there a way to do this? i.e. Is there a way to write an expression for the second table &lt;STRONG&gt;based solely&lt;/STRONG&gt; on what is shown in Table 1 in a field, &lt;STRONG&gt;independent &lt;/STRONG&gt;of user selections&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e. user selections --&amp;gt; drives Table1 output --&amp;gt; then this drives Table2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;All possible Product_ID values = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}&lt;/P&gt;&lt;P&gt;I select certain Product_ID values.&lt;/P&gt;&lt;P&gt;Based on my Table1 expression, Table1 shows records for Product_ID values = { 2, 3, 5, 6, 7, 10 }.&lt;/P&gt;&lt;P&gt;(Note, my selection is &lt;STRONG&gt;not&lt;/STRONG&gt; neccesarily { 2, 3, 5, 6, 7, 10 })&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I want Table2 to show records for Product_ID = { 1, 4, 8, 9 }.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basing Table2 on an expression driven by user selections but having an opposite effect to Table1 does not work in the case of my expressions - Therefore, I need the expression in Table2 to be essentially independent of user selections and to be like "Show records for Product_ID = Product_ID's &lt;STRONG&gt;not&lt;/STRONG&gt; in Table 1).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to do this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 08 May 2014 03:58:22 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-05-08T03:58:22Z</dc:date>
    <item>
      <title>How to write an expression to show a 'complement' table (i.e. all values not in another table for a certain field)?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-an-expression-to-show-a-complement-table-i-e-all/m-p/610223#M225210</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;I want to have 2 straight tables:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Table 1:&lt;/P&gt;&lt;P&gt;Contains 1 field (Product_ID), and 1 expression based on Sales (e.g. sum(Sales)). My expression is actually much more complicated than this, though. Based on my selections of Product_ID, certain records of Product_ID (and corresponding Sales expression value) appear in the table (dependent on my expression).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I want to create a second table so that it holds all &lt;STRONG&gt;other&lt;/STRONG&gt; records &lt;STRONG&gt;not&lt;/STRONG&gt; shown in Table 1. Is there a way to do this? i.e. Is there a way to write an expression for the second table &lt;STRONG&gt;based solely&lt;/STRONG&gt; on what is shown in Table 1 in a field, &lt;STRONG&gt;independent &lt;/STRONG&gt;of user selections&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e. user selections --&amp;gt; drives Table1 output --&amp;gt; then this drives Table2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;All possible Product_ID values = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}&lt;/P&gt;&lt;P&gt;I select certain Product_ID values.&lt;/P&gt;&lt;P&gt;Based on my Table1 expression, Table1 shows records for Product_ID values = { 2, 3, 5, 6, 7, 10 }.&lt;/P&gt;&lt;P&gt;(Note, my selection is &lt;STRONG&gt;not&lt;/STRONG&gt; neccesarily { 2, 3, 5, 6, 7, 10 })&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I want Table2 to show records for Product_ID = { 1, 4, 8, 9 }.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basing Table2 on an expression driven by user selections but having an opposite effect to Table1 does not work in the case of my expressions - Therefore, I need the expression in Table2 to be essentially independent of user selections and to be like "Show records for Product_ID = Product_ID's &lt;STRONG&gt;not&lt;/STRONG&gt; in Table 1).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to do this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 May 2014 03:58:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-an-expression-to-show-a-complement-table-i-e-all/m-p/610223#M225210</guid>
      <dc:creator />
      <dc:date>2014-05-08T03:58:22Z</dc:date>
    </item>
  </channel>
</rss>

