<?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 If Statement in Load Script Problems! in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/If-Statement-in-Load-Script-Problems/m-p/32515#M770299</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;&lt;/P&gt;&lt;P&gt;I am currently trying to join a new field to another existing table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My existing tables, consist of the fields:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;ObjectName -&amp;nbsp; which is the number of excel sheet files. IE: Sheet1, Sheet2, Sheet4......etc&lt;/LI&gt;&lt;LI&gt;IsOld - a field that has the old file sheets&lt;/LI&gt;&lt;LI&gt;IsNew - a field that has the new file sheets.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/205313_Capture.PNG" style="height: auto; width: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Code for the table: &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;NoConcatenate&lt;/SPAN&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;EffectiveObjects:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Load&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectName&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Resident&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectsList&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Where&lt;/SPAN&gt; IsOld = &lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt; and IsNew = &lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt;;&lt;/P&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code for field I want to join:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; color: #c586c0;"&gt;sub&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt; CheckTables&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #569cd6;"&gt;Load&lt;/SPAN&gt; *,&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectName,&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #dcdcaa;"&gt;if&lt;/SPAN&gt;(&lt;SPAN style="color: #dcdcaa;"&gt;NullCount&lt;/SPAN&gt;(Pick(Match(ObjectName,&lt;SPAN style="color: #ce9178;"&gt;'Sheet1'&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Sheet2'&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Sheet4'&lt;/SPAN&gt;), Old_Sheet1.ObjectID,Old_Sheet2.ObjectID,New_Sheet4.ObjectID ) )&amp;gt;&lt;SPAN style="color: #b5cea8;"&gt;0&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Table Different'&lt;/SPAN&gt;, &lt;SPAN style="color: #ce9178;"&gt;'Table Same'&lt;/SPAN&gt;) &lt;SPAN style="color: #569cd6;"&gt;AS&lt;/SPAN&gt; Checkfield;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;However, this gives me errors before I can even join the field. &lt;SPAN style="font-size: 10pt;"&gt;I want to add one more field to this table, as Difference Check, which results whether or not the two tables have any change to them. Both tables are the same, and have a key generated for each sheet. If there are any differences there will be nulls. I know my if statement works as it works in the front end but I am having extreme difficulties where it works in the script. &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;The result should look like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;IMG alt="Capture2.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/205314_Capture2.PNG" style="height: auto; width: auto;" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;Any help would be great!&lt;/P&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-11-25T16:16:04Z</dc:date>
    <item>
      <title>If Statement in Load Script Problems!</title>
      <link>https://community.qlik.com/t5/QlikView/If-Statement-in-Load-Script-Problems/m-p/32515#M770299</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;&lt;/P&gt;&lt;P&gt;I am currently trying to join a new field to another existing table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My existing tables, consist of the fields:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;ObjectName -&amp;nbsp; which is the number of excel sheet files. IE: Sheet1, Sheet2, Sheet4......etc&lt;/LI&gt;&lt;LI&gt;IsOld - a field that has the old file sheets&lt;/LI&gt;&lt;LI&gt;IsNew - a field that has the new file sheets.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/205313_Capture.PNG" style="height: auto; width: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Code for the table: &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;NoConcatenate&lt;/SPAN&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;EffectiveObjects:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Load&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectName&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Resident&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectsList&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #569cd6;"&gt;Where&lt;/SPAN&gt; IsOld = &lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt; and IsNew = &lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt;;&lt;/P&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code for field I want to join:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px; color: #c586c0;"&gt;sub&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt; CheckTables&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="color: #569cd6;"&gt;Load&lt;/SPAN&gt; *,&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectName,&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #dcdcaa;"&gt;if&lt;/SPAN&gt;(&lt;SPAN style="color: #dcdcaa;"&gt;NullCount&lt;/SPAN&gt;(Pick(Match(ObjectName,&lt;SPAN style="color: #ce9178;"&gt;'Sheet1'&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Sheet2'&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Sheet4'&lt;/SPAN&gt;), Old_Sheet1.ObjectID,Old_Sheet2.ObjectID,New_Sheet4.ObjectID ) )&amp;gt;&lt;SPAN style="color: #b5cea8;"&gt;0&lt;/SPAN&gt;,&lt;SPAN style="color: #ce9178;"&gt;'Table Different'&lt;/SPAN&gt;, &lt;SPAN style="color: #ce9178;"&gt;'Table Same'&lt;/SPAN&gt;) &lt;SPAN style="color: #569cd6;"&gt;AS&lt;/SPAN&gt; Checkfield;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;However, this gives me errors before I can even join the field. &lt;SPAN style="font-size: 10pt;"&gt;I want to add one more field to this table, as Difference Check, which results whether or not the two tables have any change to them. Both tables are the same, and have a key generated for each sheet. If there are any differences there will be nulls. I know my if statement works as it works in the front end but I am having extreme difficulties where it works in the script. &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;The result should look like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;IMG alt="Capture2.PNG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/205314_Capture2.PNG" style="height: auto; width: auto;" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;Any help would be great!&lt;/P&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/If-Statement-in-Load-Script-Problems/m-p/32515#M770299</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
  </channel>
</rss>

