<?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: DAX measure for counting values between two columns in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183101#M18523</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="237938" data-lia-user-login="goalie_" class="lia-mention lia-mention-user"&gt;goalie_&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can also have a look at this article&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sqlbi.com/articles/from-sql-to-dax-joining-tables/" target="_blank" rel="noopener"&gt;https://www.sqlbi.com/articles/from-sql-to-dax-joining-tables/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.powerbi.com/t5/Desktop/DistinctCount-for-matching-values-on-two-columns/m-p/1182531#M531771" target="_blank"&gt;https://community.powerbi.com/t5/Desktop/DistinctCount-for-matching-values-on-two-columns/m-p/1182531#M531771&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Harsh Nathani&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)&lt;/STRONG&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 25 Jun 2020 18:17:33 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-06-25T18:17:33Z</dc:date>
    <item>
      <title>DAX measure for counting values between two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183058#M18521</link>
      <description>&lt;P&gt;I have two columns, each from a different table that are linked. I want to find the count of how many distinct and similar values are between the columns.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example if one table had a column with values: [chicken, fish, rice, tree, car] and the other table's column had the values [fish, boat, rice, rice, ears, mouse], I would want the count to be 2 because rice and fish show up in both columns.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Edit: I was thinking something along the lines of a distinctcount and an innerjoin. I can't get it to work&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;COUNTROWS(NATURALINNERJOIN(SELECTCOLUMNS(&lt;EM&gt;column from table 1&lt;/EM&gt;&amp;nbsp;), SELECTCOLUMNS(&amp;nbsp;&lt;EM&gt;column from table 2&lt;/EM&gt;&amp;nbsp;))))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 25 Jun 2020 17:42:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183058#M18521</guid>
      <dc:creator>goalie_</dc:creator>
      <dc:date>2020-06-25T17:42:24Z</dc:date>
    </item>
    <item>
      <title>Re: DAX measure for counting values between two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183093#M18522</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="237938" data-lia-user-login="goalie_" class="lia-mention lia-mention-user"&gt;goalie_&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can try a measure&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE(DISTINCTCOUNT(Table1[Column1]),FILTER(CROSSJOIN(Table1,Table2), Table1[Column1] = Table2[Column1]))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Harsh Nathani&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)&lt;/STRONG&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 25 Jun 2020 18:03:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183093#M18522</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T18:03:17Z</dc:date>
    </item>
    <item>
      <title>Re: DAX measure for counting values between two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183101#M18523</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="237938" data-lia-user-login="goalie_" class="lia-mention lia-mention-user"&gt;goalie_&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can also have a look at this article&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sqlbi.com/articles/from-sql-to-dax-joining-tables/" target="_blank" rel="noopener"&gt;https://www.sqlbi.com/articles/from-sql-to-dax-joining-tables/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.powerbi.com/t5/Desktop/DistinctCount-for-matching-values-on-two-columns/m-p/1182531#M531771" target="_blank"&gt;https://community.powerbi.com/t5/Desktop/DistinctCount-for-matching-values-on-two-columns/m-p/1182531#M531771&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Harsh Nathani&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 18:17:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1183101#M18523</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T18:17:33Z</dc:date>
    </item>
    <item>
      <title>Re: DAX measure for counting values between two columns</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1189028#M18744</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;// Given: T1 and T2 that are somehow linked
// meaning a filter can be applied to both
// tables at the same time. We're interested
// in T1[col] and T2[col].

[# Same Values] =
	COUNTROWS(
		INTERSECT(
			VALUES( T1[col] ),
			VALUES(	T2[col] )
		)
	)&lt;/LI-CODE&gt;&lt;P&gt;Best&lt;/P&gt;&lt;P&gt;D&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2020 11:40:51 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-measure-for-counting-values-between-two-columns/m-p/1189028#M18744</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-29T11:40:51Z</dc:date>
    </item>
  </channel>
</rss>

