<?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: Grouping a 'if' sum expression in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758214#M720278</link>
    <description>&lt;P&gt;Unit price is related to the Codes as well as the unit price, however the orders are dated. The table is to show all order that are over a certain date by Name then value. This is working 100% but i wish then to simplify and sum that name with orders of a date as a over all total, i think the code and date is stopping it.&lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Nov 2020 17:07:30 GMT</pubDate>
    <dc:creator>bnelson111</dc:creator>
    <dc:date>2020-11-03T17:07:30Z</dc:date>
    <item>
      <title>Grouping a 'if' sum expression</title>
      <link>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758106#M720276</link>
      <description>&lt;P&gt;Below is a table export with name and order which has a Max date greater than so many days. Then if that criteria is achieved then i have below which is working perfectly. However to speed up reporting i would like it grouped.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance.&lt;/P&gt;&lt;P&gt;Please see figure 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Name&lt;/TD&gt;&lt;TD&gt;Order&lt;/TD&gt;&lt;TD&gt;Codes&lt;/TD&gt;&lt;TD&gt;Max Date&lt;/TD&gt;&lt;TD&gt;Stock Holding&lt;/TD&gt;&lt;TD&gt;Dollars&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;221045&lt;/TD&gt;&lt;TD&gt;52292&lt;/TD&gt;&lt;TD&gt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R&gt;&lt;TD&gt;Name&lt;/TD&gt;&lt;TD&gt;Dollars&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;£2,756.39&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;£3,630.47&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6&lt;/TD&gt;&lt;TD&gt;£410.71&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The expression is currently&amp;nbsp;&lt;/P&gt;&lt;P&gt;=if([Max Date]&amp;lt;=Today()-180 and CustName='4' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='3' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='2' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='1' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='5' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-90 and CustName&amp;lt;&amp;gt;'5'and CustName&amp;lt;&amp;gt; '4'and CustName&amp;lt;&amp;gt;'3'and CustName&amp;lt;&amp;gt;'2'and CustName&amp;lt;&amp;gt;'1'&lt;/P&gt;&lt;P&gt;,((sum(InventoryQty)*UnitPrice)/PriceUnitConv))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;((sum(InventoryQty)*UnitPrice)/PriceUnitConv)) = Dollars is a expression&lt;/P&gt;&lt;P&gt;CustName = Name currently a Dimension&lt;/P&gt;&lt;P&gt;Also Codes is in Dimension.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 17:53:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758106#M720276</guid>
      <dc:creator>bnelson111</dc:creator>
      <dc:date>2024-11-16T17:53:10Z</dc:date>
    </item>
    <item>
      <title>Re: Grouping a 'if' sum expression</title>
      <link>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758132#M720277</link>
      <description>&lt;P&gt;do you have sample data that shows unit price and price conv?&amp;nbsp; these should be related to products and not orders rt?&amp;nbsp; do these numbers change over time?&amp;nbsp; are they per order?&amp;nbsp; are Codes your product?&lt;/P&gt;</description>
      <pubDate>Tue, 03 Nov 2020 13:50:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758132#M720277</guid>
      <dc:creator>edwin</dc:creator>
      <dc:date>2020-11-03T13:50:01Z</dc:date>
    </item>
    <item>
      <title>Re: Grouping a 'if' sum expression</title>
      <link>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758214#M720278</link>
      <description>&lt;P&gt;Unit price is related to the Codes as well as the unit price, however the orders are dated. The table is to show all order that are over a certain date by Name then value. This is working 100% but i wish then to simplify and sum that name with orders of a date as a over all total, i think the code and date is stopping it.&lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Nov 2020 17:07:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758214#M720278</guid>
      <dc:creator>bnelson111</dc:creator>
      <dc:date>2020-11-03T17:07:30Z</dc:date>
    </item>
    <item>
      <title>Re: Grouping a 'if' sum expression</title>
      <link>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758365#M720279</link>
      <description>&lt;P&gt;Got it &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;=sum(aggr((&lt;/P&gt;&lt;P&gt;if([Max Date]&amp;lt;=Today()-180 and CustName='4' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='3' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='2' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='1' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-120 and CustName='5' or&lt;BR /&gt;[Max Date]&amp;lt;=Today()-90 and CustName&amp;lt;&amp;gt;'5'and CustName&amp;lt;&amp;gt; '4'and CustName&amp;lt;&amp;gt;'3'and CustName&amp;lt;&amp;gt;'2'and CustName&amp;lt;&amp;gt;'1'&lt;/P&gt;&lt;P&gt;,sum((InventoryQty)*UnitPrice)/PriceUnitConv)),Codes))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Nov 2020 10:22:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Grouping-a-if-sum-expression/m-p/1758365#M720279</guid>
      <dc:creator>bnelson111</dc:creator>
      <dc:date>2020-11-04T10:22:21Z</dc:date>
    </item>
  </channel>
</rss>

