<?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: Need help finding error in logic in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340366#M491990</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Now the Totals are matching, but the sum of the year expressions are not matching... Any ideas?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Aug 2012 15:40:21 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-08-06T15:40:21Z</dc:date>
    <item>
      <title>Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340361#M491985</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have several tables that show Total Revenue (sum of RevDollars) for a certain year (Year) by the year a contract was signed (StartDate). I can't find anything wrong with my expressions, but they aren't pulling correctly, so I am obviously missing something. I have attached a sample file - any help you can give me would be greatly appreciated. I am sure the problem probably lies within the null StartDate values, which I am including as older than&amp;nbsp; 2007, but I can't find where the problem is. &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, 06 Aug 2012 14:26:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340361#M491985</guid>
      <dc:creator />
      <dc:date>2012-08-06T14:26:26Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340362#M491986</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;Start by creating a key and not using the synthetic ones (this is standard practice), this will allow you to check how your data is hanging together.&amp;nbsp; I would say it may not be summing the null years.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 14:49:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340362#M491986</guid>
      <dc:creator />
      <dc:date>2012-08-06T14:49:06Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340363#M491987</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you know how I would avoid the synthetic key in this instance? The synthetic key is being caused by the IF formula I have included in my script, but I don’t know how to avoid this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:11:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340363#M491987</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:11:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340364#M491988</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rebecca&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that you are duplicating data I think&lt;BR /&gt;Try a resident load from your first table using a left join&lt;BR /&gt;I cannot give you a working example because I haven't got your excel spreadsheet&lt;/P&gt;&lt;P&gt;Table1:&lt;/P&gt;&lt;P&gt;LOAD CustomerID, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; StartDate, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RevDollars,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SalesRep,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Year,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CustomerID&amp;amp;StartDate as Key&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;C:\Users\rcamper\Desktop\Book1.xlsx&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels);&lt;/P&gt;&lt;P&gt;Left Join (Table1)&lt;/P&gt;&lt;P&gt;LOAD Key,&lt;/P&gt;&lt;P&gt;if(IsNull(StartDate)=-1,'Y','N') as StartYearIndicator&lt;/P&gt;&lt;P&gt;Resident Table1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:24:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340364#M491988</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:24:29Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340365#M491989</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That cleaned up the Synthetic Keys, but it still looks like it may be duplicating data as you suggested. Here is the updated version with the script you provided. I will upload the Excel spreadsheet also in case that helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:34:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340365#M491989</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:34:46Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340366#M491990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Now the Totals are matching, but the sum of the year expressions are not matching... Any ideas?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:40:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340366#M491990</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:40:21Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340367#M491991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rebecca&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thay key I assumed as unique may be the problem. Please let me know which combination does not repeat on your base table and use that as key&lt;BR /&gt;I will browse through the data and see if I can identify it myself, but if you already know it will help&lt;BR /&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:40:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340367#M491991</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:40:28Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340368#M491992</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Pablo – CustomerID is unique&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:44:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340368#M491992</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:44:03Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340369#M491993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I see that the expressions have this 2 modifiers, start date and year&lt;BR /&gt;sum({$&amp;lt;Year={2010},StartDate={'2010'}&amp;gt;}RevDollars) &lt;BR /&gt;This will bring the revenue of 2010 for the ones starting in 2010, is that correct?&lt;BR /&gt;If you only want revenue for customers starting in 2010 maybe you should use &lt;/P&gt;&lt;P&gt;sum({$&amp;lt;StartDate={'2010'}&amp;gt;}RevDollars) &lt;BR /&gt;If you want to disregard the selections you can try this&lt;BR /&gt;sum({1&amp;lt;Year={2010},StartDate={'2010'}&amp;gt;}RevDollars) &lt;BR /&gt;Hope it helps&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 15:51:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340369#M491993</guid>
      <dc:creator />
      <dc:date>2012-08-06T15:51:03Z</dc:date>
    </item>
    <item>
      <title>Re: Need help finding error in logic</title>
      <link>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340370#M491994</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I found my mistake and, of course, it was ridiculously obvious. Your solution above was correct. Thank you for your help!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Aug 2012 18:32:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Need-help-finding-error-in-logic/m-p/340370#M491994</guid>
      <dc:creator />
      <dc:date>2012-08-06T18:32:56Z</dc:date>
    </item>
  </channel>
</rss>

