<?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: Group By and Summarize in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300764#M123103</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="575533" data-lia-user-login="akshay2204" class="lia-mention lia-mention-user"&gt;akshay2204&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;please try&lt;/P&gt;
&lt;P&gt;NewTable =&lt;BR /&gt;GROUPBY (&lt;BR /&gt;SUMMARIZE (&lt;BR /&gt;FILTER ( vwSalesData, vwSalesData[YearID] = 22 &amp;amp;&amp;amp; vwSalesData[MonthID] = 4 ),&lt;BR /&gt;vwSalesData[CustomerCode],&lt;BR /&gt;"MajorGroupCount", DISTINCTCOUNT ( vwSalesData[MajorGroupID] )&lt;BR /&gt;),&lt;BR /&gt;[MajorGroupCount],&lt;BR /&gt;"#ofCustomers", COUNTX ( CURRENTGROUP (), 1 )&lt;BR /&gt;)&lt;/P&gt;</description>
    <pubDate>Sat, 24 Jun 2023 14:35:59 GMT</pubDate>
    <dc:creator>tamerj1</dc:creator>
    <dc:date>2023-06-24T14:35:59Z</dc:date>
    <item>
      <title>Group By and Summarize</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300741#M123099</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need solution for the following .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need a distinct count of customers who are relarted to the major group. When We ran a query in Sql we got the expected result. We are facing issue in creating the dax query for this. Please help me.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Jun 2023 13:19:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300741#M123099</guid>
      <dc:creator>akshay2204</dc:creator>
      <dc:date>2023-06-24T13:19:00Z</dc:date>
    </item>
    <item>
      <title>Re: Group By and Summarize</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300764#M123103</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="575533" data-lia-user-login="akshay2204" class="lia-mention lia-mention-user"&gt;akshay2204&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;please try&lt;/P&gt;
&lt;P&gt;NewTable =&lt;BR /&gt;GROUPBY (&lt;BR /&gt;SUMMARIZE (&lt;BR /&gt;FILTER ( vwSalesData, vwSalesData[YearID] = 22 &amp;amp;&amp;amp; vwSalesData[MonthID] = 4 ),&lt;BR /&gt;vwSalesData[CustomerCode],&lt;BR /&gt;"MajorGroupCount", DISTINCTCOUNT ( vwSalesData[MajorGroupID] )&lt;BR /&gt;),&lt;BR /&gt;[MajorGroupCount],&lt;BR /&gt;"#ofCustomers", COUNTX ( CURRENTGROUP (), 1 )&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Sat, 24 Jun 2023 14:35:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300764#M123103</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2023-06-24T14:35:59Z</dc:date>
    </item>
    <item>
      <title>Re: Group By and Summarize</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300813#M123110</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp; I checked this but still throwing an error for value conversion. Basically Year ID and Month ID will be used in slicers. we only need customer count and Major group&lt;/P&gt;</description>
      <pubDate>Sat, 24 Jun 2023 17:23:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300813#M123110</guid>
      <dc:creator>akshay2204</dc:creator>
      <dc:date>2023-06-24T17:23:33Z</dc:date>
    </item>
    <item>
      <title>Re: Group By and Summarize</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300823#M123111</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="575533" data-lia-user-login="akshay2204" class="lia-mention lia-mention-user"&gt;akshay2204&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Calculated tables cannot interact with the filter context. This has to be a measure. In this case the year and moth slicers will filter the table automatically and no need to to be included in the dax filter.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;You need to create a MajorGroupCount table. This would be a single column disconnected table that includes integers ranging from 1 to the number of unique majour groups. Can be manually inserted or created using power query or dax.&amp;nbsp;&lt;BR /&gt;A dax exsmple would be&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;MajorGroupCount =&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;SELECTCOLUMN (&lt;BR /&gt;GENERATESERIES ( 1, DISTINCTCOUNT (&amp;nbsp;vwSalesData[MajorGroupID] ), 1 ),&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;"Count", [Value]&lt;BR /&gt;)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Place MajorGroupCount[Count] in a table visual along with the following measure&amp;nbsp;&lt;/P&gt;
&lt;P&gt;CountMeasure =&lt;BR /&gt;SUMX (&lt;BR /&gt;VALUES ( MajorGroupCount[Count] ),&lt;BR /&gt;COUNTROWS (&lt;BR /&gt;FILTER (&lt;BR /&gt;SUMMARIZE (&lt;BR /&gt;vwSalesData,&lt;BR /&gt;vwSalesData[CustomerCode],&lt;BR /&gt;"MajorGroupCount", DISTINCTCOUNT ( vwSalesData[MajorGroupID] )&lt;BR /&gt;),&lt;BR /&gt;[MajorGroupCount] = MajorGroupCount[Count]&lt;BR /&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Sat, 24 Jun 2023 18:15:44 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Group-By-and-Summarize/m-p/3300823#M123111</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2023-06-24T18:15:44Z</dc:date>
    </item>
  </channel>
</rss>

