<?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 DAX Calculate by 2 category by date in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360197#M60286</link>
    <description>&lt;P&gt;Table Product&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;table time&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I have two table related to date. i want to sum per Product Category with Product category time.&amp;nbsp;i want measure speed ( good product/time) per category, i have example&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;then i try in PBI with new measure. i&amp;nbsp; have a problem when i create new measure, model like this&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Speed = &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN class=""&gt;( &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SUM('Table Product'[SKU]'), &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ('Table Product'[SKU] IN { "SKU A" })&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;/ SUM('Time'[SKU A])&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;P&gt;this model not error. but when i visualized, this measure error. this pop up&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;please your advice, thanks&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;</description>
    <pubDate>Fri, 25 Feb 2022 03:56:08 GMT</pubDate>
    <dc:creator>Wicak</dc:creator>
    <dc:date>2022-02-25T03:56:08Z</dc:date>
    <item>
      <title>DAX Calculate by 2 category by date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360197#M60286</link>
      <description>&lt;P&gt;Table Product&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;table time&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I have two table related to date. i want to sum per Product Category with Product category time.&amp;nbsp;i want measure speed ( good product/time) per category, i have example&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;then i try in PBI with new measure. i&amp;nbsp; have a problem when i create new measure, model like this&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Speed = &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN class=""&gt;( &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; SUM('Table Product'[SKU]'), &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ('Table Product'[SKU] IN { "SKU A" })&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;/ SUM('Time'[SKU A])&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;P&gt;this model not error. but when i visualized, this measure error. this pop up&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;please your advice, thanks&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 25 Feb 2022 03:56:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360197#M60286</guid>
      <dc:creator>Wicak</dc:creator>
      <dc:date>2022-02-25T03:56:08Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculate by 2 category by date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360259#M60290</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="361493" data-lia-user-login="Wicak" class="lia-mention lia-mention-user"&gt;Wicak&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Try this measure:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="php"&gt;SPEED = 
VAR _A =
    SUM ( 'Time'[SKU A] )
VAR _B =
    SUM ( 'Time'[SKU B] )
VAR _C =
    SUM ( 'Time'[SKU C] )
VAR _SGP =
    SUM ( 'Table Product'[Good Product] )
VAR _SKU =
    MAX ( 'Table Product'[SKU] )
VAR _SWSK =
    SWITCH ( _SKU, "SKU A", _A, "SKU B", _B, "SKU C", _C )
RETURN
    _SGP / _SWSK&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;output:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Download the file:&amp;nbsp;&lt;A href="https://gofile.io/d/e2BlMk" target="_blank"&gt;https://gofile.io/d/e2BlMk&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If this post&amp;nbsp;&lt;STRONG&gt;&lt;SPAN&gt;helps&lt;/SPAN&gt;&lt;/STRONG&gt;, please consider&amp;nbsp;&lt;SPAN&gt;&lt;STRONG&gt;&lt;SPAN&gt;accepting&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;it as the solution&lt;/SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/EM&gt;to help the other members find it more quickly.&lt;BR /&gt;&lt;STRONG&gt;&lt;SPAN&gt;Appreciate your Kudos!!&lt;BR /&gt;&lt;STRONG&gt;LinkedIn:&amp;nbsp;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN&gt;&lt;A href="https://www.linkedin.com/in/vahid-dm/" target="_blank" rel="noopener"&gt;www.linkedin.com/in/vahid-dm/&lt;/A&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 05:13:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360259#M60290</guid>
      <dc:creator>VahidDM</dc:creator>
      <dc:date>2022-02-25T05:13:10Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculate by 2 category by date</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360467#M60308</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="315278" data-lia-user-login="VahidDM" class="lia-mention lia-mention-user"&gt;VahidDM&lt;/a&gt;&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":beaming_face_with_smiling_eyes:"&gt;😁&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 06:54:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculate-by-2-category-by-date/m-p/2360467#M60308</guid>
      <dc:creator>Wicak</dc:creator>
      <dc:date>2022-02-25T06:54:04Z</dc:date>
    </item>
  </channel>
</rss>

