<?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: Cost Calculation in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1804772#M1212020</link>
    <description>&lt;P&gt;Try something like below:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;ID,&lt;/P&gt;&lt;P&gt;Mono,&lt;/P&gt;&lt;P&gt;Group,&lt;/P&gt;&lt;P&gt;Total&lt;/P&gt;&lt;P&gt;CostPerMono,&lt;/P&gt;&lt;P&gt;CostPerGroup,&lt;/P&gt;&lt;P&gt;CostPerMono * alt(Mono, Total*0.25) as MonoCost,&lt;/P&gt;&lt;P&gt;CostPerGroup * alt(Group, Total*0.25) As GroupCost&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 03 May 2021 22:35:47 GMT</pubDate>
    <dc:creator>Vegar</dc:creator>
    <dc:date>2021-05-03T22:35:47Z</dc:date>
    <item>
      <title>Cost Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1804725#M1212016</link>
      <description>&lt;P&gt;I have the below fields&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ID,&lt;/P&gt;&lt;P&gt;Mono,&lt;/P&gt;&lt;P&gt;Group,&lt;/P&gt;&lt;P&gt;Total&lt;/P&gt;&lt;P&gt;CostPerMono,&lt;/P&gt;&lt;P&gt;CostPerGroup&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to create Costs such that&lt;/P&gt;&lt;P&gt;If an ID has values in either Mono or Group or both,&lt;/P&gt;&lt;P&gt;MonoCost = CostPerMono * Mono&lt;/P&gt;&lt;P&gt;GroupCost = CostPerGroup * Group&lt;/P&gt;&lt;P&gt;If an ID has no values in Mono and Group fields, then&amp;nbsp;&lt;/P&gt;&lt;P&gt;MonoCost = 25% of Total * CostPerMono&lt;/P&gt;&lt;P&gt;GroupCost = 75% of Total * CostPerGroup.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How do I do this in the script ?&lt;/P&gt;</description>
      <pubDate>Mon, 03 May 2021 19:10:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1804725#M1212016</guid>
      <dc:creator>qlikwiz123</dc:creator>
      <dc:date>2021-05-03T19:10:45Z</dc:date>
    </item>
    <item>
      <title>Re: Cost Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1804772#M1212020</link>
      <description>&lt;P&gt;Try something like below:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;ID,&lt;/P&gt;&lt;P&gt;Mono,&lt;/P&gt;&lt;P&gt;Group,&lt;/P&gt;&lt;P&gt;Total&lt;/P&gt;&lt;P&gt;CostPerMono,&lt;/P&gt;&lt;P&gt;CostPerGroup,&lt;/P&gt;&lt;P&gt;CostPerMono * alt(Mono, Total*0.25) as MonoCost,&lt;/P&gt;&lt;P&gt;CostPerGroup * alt(Group, Total*0.25) As GroupCost&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 03 May 2021 22:35:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1804772#M1212020</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2021-05-03T22:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: Cost Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1805620#M1212072</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/25001"&gt;@Vegar&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you. Had to tweak it to check for null values.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 19:08:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Cost-Calculation/m-p/1805620#M1212072</guid>
      <dc:creator>qlikwiz123</dc:creator>
      <dc:date>2021-05-05T19:08:09Z</dc:date>
    </item>
  </channel>
</rss>

