<?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: Load Script If Help in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975642#M969896</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The If statement is declaring a subset of costs to divide by the total cost. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Sep 2015 21:45:58 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-09-17T21:45:58Z</dc:date>
    <item>
      <title>Load Script If Help</title>
      <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975640#M969894</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I keep getting Invalid Expression with the following load script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Insource%:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;AcctDesc,&lt;/P&gt;&lt;P&gt;Cost,&lt;/P&gt;&lt;P&gt;If(AcctDesc='Demand Service' or AcctDesc='Demand Parts',Sum(Cost),0)/Sum(Cost) as Insource&lt;/P&gt;&lt;P&gt;Resident MasterCostTable;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Sep 2015 21:27:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975640#M969894</guid>
      <dc:creator />
      <dc:date>2015-09-17T21:27:08Z</dc:date>
    </item>
    <item>
      <title>Re: Load Script If Help</title>
      <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975641#M969895</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;- add a group by&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;- I don't understand the if, it seems sum(Cost) / sum(Cost)&amp;nbsp;&amp;nbsp;&amp;nbsp; or&amp;nbsp;&amp;nbsp; 0 / sum(Cost), so&amp;nbsp; 1&amp;nbsp; or 0 &lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Insource%:&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Load&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;AcctDesc,&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Cost,&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;//If(AcctDesc='Demand Service' or AcctDesc='Demand Parts',Sum(Cost),0)/Sum(Cost) as Insource&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;If(AcctDesc='Demand Service' or AcctDesc='Demand Parts',Sum(Cost),0) as Insource&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Resident MasterCostTable&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;group by AcctDesc, Cost&lt;/STRONG&gt;&lt;SPAN style="line-height: 1.5em;"&gt;&lt;STRONG&gt;;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Sep 2015 21:37:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975641#M969895</guid>
      <dc:creator>maxgro</dc:creator>
      <dc:date>2015-09-17T21:37:28Z</dc:date>
    </item>
    <item>
      <title>Re: Load Script If Help</title>
      <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975642#M969896</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The If statement is declaring a subset of costs to divide by the total cost. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Sep 2015 21:45:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975642#M969896</guid>
      <dc:creator />
      <dc:date>2015-09-17T21:45:58Z</dc:date>
    </item>
    <item>
      <title>Re: Load Script If Help</title>
      <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975643#M969897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What Maxgro said.&lt;/P&gt;&lt;P&gt;Maybe this if you actually want your costs summed up in the script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Insource%:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;AcctDesc,&lt;/P&gt;&lt;P&gt;sum(Cost)as Cost,&lt;/P&gt;&lt;P&gt;sum(If(&lt;SPAN style="font-size: 13.3333px;"&gt;AcctDesc&lt;/SPAN&gt;='&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Demand Service&lt;/STRONG&gt;' or AcctDesc='&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Demand Parts&lt;/STRONG&gt;',Cost,0))/Sum(Cost) as Insource&lt;/P&gt;&lt;P&gt;Resident MasterCostTable&lt;/P&gt;&lt;P&gt;group by AcctDesc;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Sep 2015 21:46:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975643#M969897</guid>
      <dc:creator>datagrrl</dc:creator>
      <dc:date>2015-09-17T21:46:33Z</dc:date>
    </item>
    <item>
      <title>Re: Load Script If Help</title>
      <link>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975644#M969898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am wondering if you wouldn't want to do this in a chart. Then you could use the Total keyword in your expression.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Sep 2015 22:08:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Load-Script-If-Help/m-p/975644#M969898</guid>
      <dc:creator>datagrrl</dc:creator>
      <dc:date>2015-09-17T22:08:11Z</dc:date>
    </item>
  </channel>
</rss>

