<?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: How do I exclude/delete records in a fact table based on a value in another table? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83194#M608519</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Vamshi , &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt; NOT EXISTS(&lt;/SPAN&gt;&lt;STRONG style="font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d; background-color: #f2f2f2;"&gt;OrderStatus&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;, OrderStatus); Compares values of Field(1st in arguments) from Current table from the already available field (2nd in the arguments)in the memory..&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you could try just where not exists(OrderStatus) if incase you want to use only same field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please mark Helpful or Answered so that it helps for the community.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;CY&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 12 Feb 2018 18:08:46 GMT</pubDate>
    <dc:creator>ychaitanya</dc:creator>
    <dc:date>2018-02-12T18:08:46Z</dc:date>
    <item>
      <title>How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83189#M608514</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;Fact Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="124" style="border: 1px solid rgb(0, 0, 0); width: 188px; height: 20px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Order#&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Amount&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;OrderStatus&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;1&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;100&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;FIRM&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;2&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;200&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;CANCELLED&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;3&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;300&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;DELETED&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;DeleteOrderStatus:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="74" style="border: 1px solid #000000; width: 128px; height: 55px;" width="126"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;OrderStatus&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;CANCELLED&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;DELETED&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Desired Output in Fact Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" height="49" style="border: 1px solid #000000; width: 212px; height: 32px;" width="210"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Order#&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Amount&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;OrderStatus&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;1&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;100&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;FIRM&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After loading the Fact table, I would like to delete records that have certain OrderStatus that are in 'DeleteOrderStatus' table. Using KEEP/INNER JOIN, I was able to include certain records. Is there a way I can exclude certain records based on another table?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Feb 2018 20:38:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83189#M608514</guid>
      <dc:creator>vamshi87</dc:creator>
      <dc:date>2018-02-09T20:38:27Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83190#M608515</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use the Exists() function in a WHERE clause:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Filter:&lt;/P&gt;&lt;P&gt;LOAD OrderStatus as Status2Exclude&lt;/P&gt;&lt;P&gt;FROM DeleteOrderStatus;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Facts:&lt;/P&gt;&lt;P&gt;LOAD * FROM FactTable&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;WHERE NOT EXISTS(Status2Exclude, OrderStatus);&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Feb 2018 21:08:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83190#M608515</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2018-02-09T21:08:01Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83191#M608516</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Exists() is the way to go!&lt;/P&gt;&lt;P&gt;Additionally, if you want to keep your load optimized (if qvd is your source), dont't rename OrderStatus field and use:&lt;/P&gt;&lt;P&gt;where not Exists(OrderStatus). It is faster.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Feb 2018 19:06:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83191#M608516</guid>
      <dc:creator>michal__</dc:creator>
      <dc:date>2018-02-11T19:06:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83192#M608517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As Stefan mentioned where not exists() would be the ideal one to handle this . Please let us know if that didn't&amp;nbsp; work &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 14:29:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83192#M608517</guid>
      <dc:creator>ychaitanya</dc:creator>
      <dc:date>2018-02-12T14:29:04Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83193#M608518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It worked. Thank you Stefan and Raviteja.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any reason why the field name in the filter was changed? The reason I am asking is when I tried to use the same field name twice as below, the filter did not work properly. Could you please explain why the below ocde does not work?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Filter:&lt;/P&gt;&lt;P&gt;LOAD &lt;STRONG&gt;OrderStatus &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;FROM DeleteOrderStatus;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Facts:&lt;/P&gt;&lt;P&gt;LOAD * FROM FactTable&lt;/P&gt;&lt;P&gt;WHERE NOT EXISTS(&lt;STRONG&gt;OrderStatus&lt;/STRONG&gt;, OrderStatus);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 16:07:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83193#M608518</guid>
      <dc:creator>vamshi87</dc:creator>
      <dc:date>2018-02-12T16:07:16Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83194#M608519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Vamshi , &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt; NOT EXISTS(&lt;/SPAN&gt;&lt;STRONG style="font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d; background-color: #f2f2f2;"&gt;OrderStatus&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;, OrderStatus); Compares values of Field(1st in arguments) from Current table from the already available field (2nd in the arguments)in the memory..&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you could try just where not exists(OrderStatus) if incase you want to use only same field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please mark Helpful or Answered so that it helps for the community.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;CY&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 18:08:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83194#M608519</guid>
      <dc:creator>ychaitanya</dc:creator>
      <dc:date>2018-02-12T18:08:46Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83195#M608520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Raviteja for the clarification.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 18:16:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83195#M608520</guid>
      <dc:creator>vamshi87</dc:creator>
      <dc:date>2018-02-12T18:16:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83196#M608521</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please mark as Answered to close the thread.. Have a great day.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 18:36:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83196#M608521</guid>
      <dc:creator>ychaitanya</dc:creator>
      <dc:date>2018-02-12T18:36:10Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83197#M608522</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When using &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;WHERE NOT EXISTS(OrderStatus);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of the two argument version, you won't get all requested records if OrderStatus is not a primary key (which I assume it is not).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In other words, as soon as your LOAD encountered the first record with OrderStatus FIRM, FIRM is part of the symbols that the exists() function checks the upcoming record values against. Hence, no other records with OrderStatus FIRM will pass the WHERE clause and will be loaded to the resident output table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I guess that's what you see when you are mentioning that this approach 'will not work properly', right?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Feb 2018 19:53:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83197#M608522</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2018-02-12T19:53:49Z</dc:date>
    </item>
    <item>
      <title>Re: How do I exclude/delete records in a fact table based on a value in another table?</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83198#M608523</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Stefan and Chaitanya!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Feb 2018 15:48:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-exclude-delete-records-in-a-fact-table-based-on-a-value/m-p/83198#M608523</guid>
      <dc:creator>vamshi87</dc:creator>
      <dc:date>2018-02-14T15:48:31Z</dc:date>
    </item>
  </channel>
</rss>

