<?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: calculate sum with multiple criteria in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3301310#M123148</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="484486" data-lia-user-login="alsm" class="lia-mention lia-mention-user"&gt;alsm&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Would you give me an example of what you mean?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Let me know if you have any questions.&lt;BR /&gt;&lt;BR /&gt;If this solves your issues, please mark it as the &lt;STRONG&gt;solution, &lt;/STRONG&gt;so that others can find it easily. &lt;STRONG&gt;Kudos &lt;/STRONG&gt;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;are nice too.&lt;BR /&gt;Nathaniel&lt;/P&gt;</description>
    <pubDate>Mon, 26 Jun 2023 01:01:12 GMT</pubDate>
    <dc:creator>Nathaniel_C</dc:creator>
    <dc:date>2023-06-26T01:01:12Z</dc:date>
    <item>
      <title>calculate sum with multiple criteria</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3300687#M123097</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;I have a table that somewhat looks like&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;STRONG&gt;Industry&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD&gt;&lt;STRONG&gt;Sub-Industry&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD&gt;&lt;STRONG&gt;Volume&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Energy Equipment &amp;amp; Services&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Drilling&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;100&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Energy Equipment &amp;amp; Services&lt;/TD&gt;&lt;TD&gt;Oil &amp;amp; Gas Equipment &amp;amp; Services&lt;/TD&gt;&lt;TD&gt;150&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Oil, Gas &amp;amp; Consumable Fuels&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Drilling&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;50&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Oil, Gas &amp;amp; Consumable Fuels&lt;/TD&gt;&lt;TD&gt;Integrated Oil &amp;amp; Gas&lt;/TD&gt;&lt;TD&gt;75&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Oil, Gas &amp;amp; Consumable Fuels&lt;/TD&gt;&lt;TD&gt;Oil &amp;amp; Gas Exploration &amp;amp; Production&lt;/TD&gt;&lt;TD&gt;200&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Metals &amp;amp; Mining&lt;/TD&gt;&lt;TD&gt;Drilling&lt;/TD&gt;&lt;TD&gt;225&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Metals &amp;amp; Mining&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;Diversified Metals &amp;amp; Mining&lt;/FONT&gt;&lt;/TD&gt;&lt;TD&gt;&lt;FONT color="#008000"&gt;90&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Metals &amp;amp; Mining&lt;/TD&gt;&lt;TD&gt;Copper&lt;/TD&gt;&lt;TD&gt;75&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to calculate sum with following filter criteria&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Industry IN {&lt;FONT color="#008000"&gt;Energy Equipment &amp;amp; Services,&amp;nbsp;Oil, Gas &amp;amp; Consumable Fuels&lt;/FONT&gt;} and&amp;nbsp;Sub-Industry =&amp;nbsp;&lt;FONT color="#008000"&gt;Drilling&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;OR&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#008000"&gt;&lt;FONT color="#000000"&gt;Industry IN&lt;/FONT&gt; {Metals &amp;amp; Mining}&amp;nbsp;&lt;FONT color="#000000"&gt;and&amp;nbsp;Sub-Industry =&lt;/FONT&gt; 'Diversified Metals &amp;amp; Mining'&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;How to write this combination of AND and OR conditions in Calculate(Sum(Volume),..???..)&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Jun 2023 10:07:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3300687#M123097</guid>
      <dc:creator>alsm</dc:creator>
      <dc:date>2023-06-24T10:07:52Z</dc:date>
    </item>
    <item>
      <title>Re: calculate sum with multiple criteria</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3300886#M123118</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="484486" data-lia-user-login="alsm" class="lia-mention lia-mention-user"&gt;alsm&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;&lt;BR /&gt;There are many ways to write this, however this works:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Sum =
CALCULATE (
    SUM ( IndustryResearch[Volume] ),
    FILTER (
        IndustryResearch,
        IndustryResearch[Industry]
            IN { "Energy Equipment &amp;amp; Services", "Oil, Gas &amp;amp; Consumable Fuels" }
            &amp;amp;&amp;amp; IndustryResearch[Sub-Industry] = "Drilling"
    )
)
    + CALCULATE (
        SUM ( IndustryResearch[Volume] ),
        FILTER (
            IndustryResearch,
            IndustryResearch[Industry] = "Metals &amp;amp; Mining"
                &amp;amp;&amp;amp; IndustryResearch[Sub-Industry] = "Diversified Metals &amp;amp; Mining"
        )
    )
&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;img /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Let me know if you have any questions.&lt;BR /&gt;&lt;BR /&gt;If this solves your issues, please mark it as the &lt;STRONG&gt;solution, &lt;/STRONG&gt;so that others can find it easily. &lt;STRONG&gt;Kudos &lt;/STRONG&gt;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;are nice too.&lt;BR /&gt;Nathaniel&lt;/P&gt;</description>
      <pubDate>Sun, 25 Jun 2023 00:14:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3300886#M123118</guid>
      <dc:creator>Nathaniel_C</dc:creator>
      <dc:date>2023-06-25T00:14:25Z</dc:date>
    </item>
    <item>
      <title>Re: calculate sum with multiple criteria</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3301241#M123145</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="159166" data-lia-user-login="Nathaniel_C" class="lia-mention lia-mention-user"&gt;Nathaniel_C&lt;/a&gt;&amp;nbsp;Thank you for your reply, it works. I have a followup question (don't know if I should ask another question or simply here). Can I create a filter variable which has common filter criteria and then use this common filter + additional filter lines in each calculate rows?&lt;/P&gt;</description>
      <pubDate>Sun, 25 Jun 2023 21:43:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3301241#M123145</guid>
      <dc:creator>alsm</dc:creator>
      <dc:date>2023-06-25T21:43:58Z</dc:date>
    </item>
    <item>
      <title>Re: calculate sum with multiple criteria</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3301310#M123148</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="484486" data-lia-user-login="alsm" class="lia-mention lia-mention-user"&gt;alsm&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Would you give me an example of what you mean?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Let me know if you have any questions.&lt;BR /&gt;&lt;BR /&gt;If this solves your issues, please mark it as the &lt;STRONG&gt;solution, &lt;/STRONG&gt;so that others can find it easily. &lt;STRONG&gt;Kudos &lt;/STRONG&gt;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;are nice too.&lt;BR /&gt;Nathaniel&lt;/P&gt;</description>
      <pubDate>Mon, 26 Jun 2023 01:01:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/calculate-sum-with-multiple-criteria/m-p/3301310#M123148</guid>
      <dc:creator>Nathaniel_C</dc:creator>
      <dc:date>2023-06-26T01:01:12Z</dc:date>
    </item>
  </channel>
</rss>

