<?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: Distinc count filter from different table in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2867049#M92403</link>
    <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;Here is an alternative approach:&lt;BR /&gt;&lt;BR /&gt;Data:&lt;BR /&gt;&lt;BR /&gt;table (9)&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;table (10)&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Dax:&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Measure 20 = &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;BR /&gt;&lt;BR /&gt;
&lt;DIV&gt;&lt;SPAN&gt;SUMX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DISTINCT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;('Table (9)','Table (9)'[Dim2] &lt;/SPAN&gt;&lt;SPAN&gt;in&lt;/SPAN&gt; &lt;SPAN&gt;VALUES&lt;/SPAN&gt;&lt;SPAN&gt;('Table (10)'[Dim2]))),'Table (9)'[Value])&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;End result:&lt;BR /&gt;&lt;img /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
The result is 2 as expected since only values containing Dim2 = A1 are considered. This leaves 3 rows 2 of which are distinct.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!&lt;BR /&gt;&lt;BR /&gt;My LinkedIn: &lt;A href="https://www.linkedin.com/in/n%C3%A4ttiahov-00001/" target="_blank"&gt;https://www.linkedin.com/in/n%C3%A4ttiahov-00001/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
    <pubDate>Thu, 27 Oct 2022 07:39:14 GMT</pubDate>
    <dc:creator>ValtteriN</dc:creator>
    <dc:date>2022-10-27T07:39:14Z</dc:date>
    <item>
      <title>Distinc count filter from different table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2866940#M92402</link>
      <description>&lt;P&gt;Hello All&lt;/P&gt;&lt;P&gt;I would like to re-create a measure what seems to be working in one reporting but not working in mine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The formula is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE(DISTINCTCOUNT(Data[ID]), 'Production Plan'[PNCode] = VALUES(Data[PNCode]) )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;The Production plan and data tables are not connected they have a dimension table together.&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;I tried to trim, clean and lower case the PNCode colums, but nothing seems to help. ( it seems that the filter part is not OK)&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;The problem is that the same ID is appearing on multiple operations but I want to filter only those which are on the same opeartion what was planned&lt;/DIV&gt;&lt;DIV&gt;SO same ID on operation 1, 2, 3 above one department but in planning we have only operation 1&lt;/DIV&gt;&lt;DIV&gt;And i would like to filter from data only unique ID with operation one. ( now the result is 3 because 1 ID 3 operations)&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Thank you&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 27 Oct 2022 07:13:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2866940#M92402</guid>
      <dc:creator>Tommyvhod</dc:creator>
      <dc:date>2022-10-27T07:13:08Z</dc:date>
    </item>
    <item>
      <title>Re: Distinc count filter from different table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2867049#M92403</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;Here is an alternative approach:&lt;BR /&gt;&lt;BR /&gt;Data:&lt;BR /&gt;&lt;BR /&gt;table (9)&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;table (10)&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Dax:&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Measure 20 = &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;BR /&gt;&lt;BR /&gt;
&lt;DIV&gt;&lt;SPAN&gt;SUMX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;DISTINCT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;('Table (9)','Table (9)'[Dim2] &lt;/SPAN&gt;&lt;SPAN&gt;in&lt;/SPAN&gt; &lt;SPAN&gt;VALUES&lt;/SPAN&gt;&lt;SPAN&gt;('Table (10)'[Dim2]))),'Table (9)'[Value])&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;End result:&lt;BR /&gt;&lt;img /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
The result is 2 as expected since only values containing Dim2 = A1 are considered. This leaves 3 rows 2 of which are distinct.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!&lt;BR /&gt;&lt;BR /&gt;My LinkedIn: &lt;A href="https://www.linkedin.com/in/n%C3%A4ttiahov-00001/" target="_blank"&gt;https://www.linkedin.com/in/n%C3%A4ttiahov-00001/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Thu, 27 Oct 2022 07:39:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2867049#M92403</guid>
      <dc:creator>ValtteriN</dc:creator>
      <dc:date>2022-10-27T07:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: Distinc count filter from different table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2867215#M92411</link>
      <description>&lt;P&gt;Thank you. It is working.&lt;/P&gt;</description>
      <pubDate>Thu, 27 Oct 2022 08:21:03 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Distinc-count-filter-from-different-table/m-p/2867215#M92411</guid>
      <dc:creator>Tommyvhod</dc:creator>
      <dc:date>2022-10-27T08:21:03Z</dc:date>
    </item>
  </channel>
</rss>

