<?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 Seemingly Simple Problem With Counting Rows in Desktop</title>
    <link>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461079#M213909</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a fairly straightforward requirement that I can't seem to crack. Here's the situation:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;DimMatterInfo (Matter # is primary key)&lt;/P&gt;&lt;P&gt;DimTimekeeper (TKID is primary key)&lt;/P&gt;&lt;P&gt;DimTitle&amp;nbsp;(Title is primary key)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Measures that are working:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Total Billable Hours Worked]&lt;/STRONG&gt; = SUM( 'Matter Fact'[Billable Hours Worked] )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Billable Hours Worked Feb-June] =&lt;BR /&gt;&lt;/STRONG&gt;&amp;nbsp; &amp;nbsp; CALCULATE(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; [Total Billable Hours Worked],&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; DimPeriod[period_month_num] &amp;gt;= 2 &amp;amp;&amp;amp; DimPeriod[period_month_num] &amp;lt;= 6&lt;BR /&gt;&amp;nbsp; &amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Analyst Hours Worked]&lt;/STRONG&gt; =&lt;BR /&gt;&amp;nbsp; CALCULATE (&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; [Total Billable Hours Worked],&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Timekeeper[Title] = "Analyst"&lt;BR /&gt;&amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The key requirement, and what's tripping me up, is that I only want to run metrics on matters with &lt;STRONG&gt;[Total Billable Hours Worked Feb-June]&lt;/STRONG&gt; &amp;gt; 20. I've achieved this on the visual using the visual level filter on the table shown above.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I'm trying to write is a measure that calculates&amp;nbsp;&lt;STRONG&gt;average Analyst Hours Per Job&lt;/STRONG&gt;, subject to the overall limitation that the &lt;STRONG&gt;[Total Billable Hours Worked] &amp;gt;&lt;/STRONG&gt; 20. So in the above example, the measure would be: (19.0 + 49.5 + 33.5) / 3 = 34.0. Basically, I need a formula that returns "3" for the non-blank analyst rows, subject to the&amp;nbsp;&lt;STRONG&gt;[Total Billable Hours Worked Feb-June] &amp;gt;&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;20 limitation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm ultimately not going to show the&amp;nbsp;&lt;STRONG&gt;[Total Billable Hours Worked Feb-June]&lt;/STRONG&gt; on the table -- it's just needed for a filter.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any help would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 12 Jul 2018 14:42:20 GMT</pubDate>
    <dc:creator>jl20</dc:creator>
    <dc:date>2018-07-12T14:42:20Z</dc:date>
    <item>
      <title>Seemingly Simple Problem With Counting Rows</title>
      <link>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461079#M213909</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a fairly straightforward requirement that I can't seem to crack. Here's the situation:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;DimMatterInfo (Matter # is primary key)&lt;/P&gt;&lt;P&gt;DimTimekeeper (TKID is primary key)&lt;/P&gt;&lt;P&gt;DimTitle&amp;nbsp;(Title is primary key)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Measures that are working:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Total Billable Hours Worked]&lt;/STRONG&gt; = SUM( 'Matter Fact'[Billable Hours Worked] )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Billable Hours Worked Feb-June] =&lt;BR /&gt;&lt;/STRONG&gt;&amp;nbsp; &amp;nbsp; CALCULATE(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; [Total Billable Hours Worked],&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; DimPeriod[period_month_num] &amp;gt;= 2 &amp;amp;&amp;amp; DimPeriod[period_month_num] &amp;lt;= 6&lt;BR /&gt;&amp;nbsp; &amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;[Analyst Hours Worked]&lt;/STRONG&gt; =&lt;BR /&gt;&amp;nbsp; CALCULATE (&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; [Total Billable Hours Worked],&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Timekeeper[Title] = "Analyst"&lt;BR /&gt;&amp;nbsp; )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The key requirement, and what's tripping me up, is that I only want to run metrics on matters with &lt;STRONG&gt;[Total Billable Hours Worked Feb-June]&lt;/STRONG&gt; &amp;gt; 20. I've achieved this on the visual using the visual level filter on the table shown above.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I'm trying to write is a measure that calculates&amp;nbsp;&lt;STRONG&gt;average Analyst Hours Per Job&lt;/STRONG&gt;, subject to the overall limitation that the &lt;STRONG&gt;[Total Billable Hours Worked] &amp;gt;&lt;/STRONG&gt; 20. So in the above example, the measure would be: (19.0 + 49.5 + 33.5) / 3 = 34.0. Basically, I need a formula that returns "3" for the non-blank analyst rows, subject to the&amp;nbsp;&lt;STRONG&gt;[Total Billable Hours Worked Feb-June] &amp;gt;&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;20 limitation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm ultimately not going to show the&amp;nbsp;&lt;STRONG&gt;[Total Billable Hours Worked Feb-June]&lt;/STRONG&gt; on the table -- it's just needed for a filter.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any help would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Jul 2018 14:42:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461079#M213909</guid>
      <dc:creator>jl20</dc:creator>
      <dc:date>2018-07-12T14:42:20Z</dc:date>
    </item>
    <item>
      <title>Re: Seemingly Simple Problem With Counting Rows</title>
      <link>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461203#M213983</link>
      <description>Use a measure that leveages SUMMARIZE to build a temp table as a VAR that mirrors you table visualization. Then simply use FILTER to filter that down and return what you want.</description>
      <pubDate>Thu, 12 Jul 2018 16:36:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461203#M213983</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2018-07-12T16:36:21Z</dc:date>
    </item>
    <item>
      <title>Re: Seemingly Simple Problem With Counting Rows</title>
      <link>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461247#M214008</link>
      <description>&lt;P&gt;I've tried the following formula, but it's returning 6 rows (the correct answer should be 3). Obviously I need to filter to only show "Analyst" which comes from a related table. I guess at this point I'm not sure if I need to modify the SUMMARIZE statement or somehow filter using a RELATED function?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Analyst # of Matters =&lt;BR /&gt;VAR TempTable =&lt;BR /&gt;&amp;nbsp; &amp;nbsp;FILTER(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; SUMMARIZE('Matter Fact',&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;'Matter Fact'[Matter #],&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;"Total Hours Worked", SUM( 'Matter Fact'[Billable Hours Worked] )&lt;BR /&gt;&amp;nbsp; &amp;nbsp;),&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; [Total Hours Worked] &amp;gt; 20&lt;BR /&gt;)&lt;BR /&gt;RETURN&lt;BR /&gt;&amp;nbsp; &amp;nbsp;COUNTROWS(TempTable)&lt;/P&gt;</description>
      <pubDate>Thu, 12 Jul 2018 17:28:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Desktop/Seemingly-Simple-Problem-With-Counting-Rows/m-p/461247#M214008</guid>
      <dc:creator>jl20</dc:creator>
      <dc:date>2018-07-12T17:28:41Z</dc:date>
    </item>
  </channel>
</rss>

