<?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: Problems with COUNT in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489408#M68481</link>
    <description>&lt;P&gt;Best:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 02 May 2022 19:21:48 GMT</pubDate>
    <dc:creator>elandry9840</dc:creator>
    <dc:date>2022-05-02T19:21:48Z</dc:date>
    <item>
      <title>Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489361#M68473</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;First post here. This should be simple for an experienced DAX person, and I'd greatly appreciate a suggestion or two. I have a table with weekly stock closing prices for a few thousand tickers. I want to calc the 40-week moving average for each ticker on each week, then count the number of tickers trading below their moving average for each week. Simple, but I can't get the last part...the count.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is the MA calc, which works perfectly:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;40-week MA = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;AVERAGEX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DATESBETWEEN&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;max&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;) - &lt;/SPAN&gt;&lt;SPAN&gt;200&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;max&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;)),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Calculate&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;sum&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;PriceTable[closeadj]&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;To count the number trading below the MA I'm using:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Number of Stocks &amp;lt; 200Day MA = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;COUNTROWS&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;filter&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'PriceTable'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;PriceTable[closeadj]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt; &lt;/SPAN&gt;&lt;SPAN&gt;[40-week MA]&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;This returns nothing, unfortunately.&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;The model is simple, with only 1 fact table (weekly pricetable) and two DIM tables (Calendar and Tickers). Can somebody please suggest what I'm doing wrong?&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Thanks&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;BR /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 02 May 2022 18:57:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489361#M68473</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T18:57:09Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489375#M68474</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;how does your report look like? Can you share a screenshot of your data model?&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:08:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489375#M68474</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-02T19:08:14Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489393#M68478</link>
      <description>&lt;P&gt;Sure thing! Thanks for the reply!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Not sure if this will be big enough. If not, let me know.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:17:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489393#M68478</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T19:17:00Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489397#M68479</link>
      <description>&lt;P&gt;This is better:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:18:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489397#M68479</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T19:18:46Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489399#M68480</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The screenshot is very small. However please try&lt;/P&gt;&lt;P&gt;Number of Stocks &amp;lt; 200Day MA =&lt;BR /&gt;VAR FortyWeekMA = [40-week MA]&lt;BR /&gt;RETURN&lt;BR /&gt;COUNTROWS ( FILTER ( 'PriceTable', PriceTable[closeadj] &amp;lt; FortyWeekMA ) )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:19:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489399#M68480</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-02T19:19:21Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489408#M68481</link>
      <description>&lt;P&gt;Best:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:21:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489408#M68481</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T19:21:48Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489431#M68483</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Have you tried above code?&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:32:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489431#M68483</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-02T19:32:18Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489455#M68487</link>
      <description>&lt;P&gt;Yes. Thank you, but doesn't seem to work. Must be something in my model that is peculiar.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 19:53:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489455#M68487</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T19:53:24Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489470#M68489</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please use the variable name inside FILTER same as the code I have shared&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 20:02:43 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489470#M68489</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-02T20:02:43Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489492#M68493</link>
      <description>&lt;P&gt;Sorry. Here it is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 20:23:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489492#M68493</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T20:23:48Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489494#M68494</link>
      <description>&lt;P&gt;Replied to above&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 20:25:26 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489494#M68494</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T20:25:26Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489507#M68496</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Would you please add the moving average measure and snother measure: COUNTROWS&lt;SPAN&gt;&amp;nbsp;( 'PriceTable')&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 20:37:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489507#M68496</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-02T20:37:19Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489522#M68500</link>
      <description>&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Thank you so much for the help! I have to step out for an hour, but will be back after that and will reply promptly to whatever you need.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2022 20:49:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2489522#M68500</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-02T20:49:22Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2490117#M68525</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I apologize as well. It was too late and I fell asleep.&amp;nbsp;&lt;BR /&gt;Are you sure you have a relationship. The results are not filtered at all. There is something wrong here&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 06:47:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2490117#M68525</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-03T06:47:21Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491179#M68589</link>
      <description>&lt;P&gt;Thanks. I went back and deleted them then recreated them. Still no luck.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&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;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 14:36:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491179#M68589</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-03T14:36:31Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491266#M68593</link>
      <description>&lt;P&gt;If possible, can you share a sample file?&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 15:24:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491266#M68593</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-03T15:24:34Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491484#M68608</link>
      <description>&lt;P&gt;Sure. How do I do that?&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 17:16:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491484#M68608</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-03T17:16:48Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491526#M68611</link>
      <description>&lt;P&gt;You can upload for example to We Transfer, DropBox or OneDrive and share the link&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 17:44:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2491526#M68611</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-05-03T17:44:25Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2495316#M68811</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="312566" data-lia-user-login="elandry9840" class="lia-mention lia-mention-user"&gt;elandry9840&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Not sure, is the first measure wrong?&amp;nbsp;&lt;BR /&gt;Please use this measure and test.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;40-week MA =
CALCULATE (
    AVERAGE ( PriceTable[closeadj] ),
    FILTER (
        'Calendar',
        'Calendar'[Date] &amp;lt;= MAX ( 'Calendar'[Date] )
            &amp;amp;&amp;amp; 'Calendar'[Date]
                &amp;gt;= MAX ( 'Calendar'[Date] ) - 200
    )
)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Attached PBIX file for reference.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT size="2"&gt;Best Regards,&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size="2"&gt;Gao&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;Community Support Team&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT size="2"&gt;If there is any post&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT size="3" color="#FF0000"&gt;&lt;EM&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/EM&gt;&lt;/FONT&gt;, then please consider&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT size="3"&gt;&lt;FONT color="#FF0000"&gt;&lt;EM&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/EM&gt;&lt;/FONT&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;to help the other members find it more quickly. If I misunderstand your needs or you still have problems with it, please feel free to let us know.&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;FONT size="3"&gt;Thanks a lot!&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/EM&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2022 07:38:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2495316#M68811</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-05-05T07:38:53Z</dc:date>
    </item>
    <item>
      <title>Re: Problems with COUNT</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2496661#M68912</link>
      <description>&lt;P&gt;Hi v-cgao-msft,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Appreciate the reply!! I'm not sure it's working tho. Take a look:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;40-week MA (New) = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;AVERAGE&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;PriceTable[closeadj]&lt;/SPAN&gt;&lt;SPAN&gt; ),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;'Calendar'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt;= &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;gt;= &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt; ) - &lt;/SPAN&gt;&lt;SPAN&gt;200&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;40-week MA = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;AVERAGEX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DATESBETWEEN&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;max&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;) - &lt;/SPAN&gt;&lt;SPAN&gt;200&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;max&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'[Date]&lt;/SPAN&gt;&lt;SPAN&gt;)),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;calculate&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;sum&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;PriceTable[closeadj]&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Looks like [40-Wk MA (New)] is returning the closeadj. See below:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could it have something to do with the price table having data only once per week? I noticed your price table had dailt prices.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 05 May 2022 16:55:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Problems-with-COUNT/m-p/2496661#M68912</guid>
      <dc:creator>elandry9840</dc:creator>
      <dc:date>2022-05-05T16:55:59Z</dc:date>
    </item>
  </channel>
</rss>

