<?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: Plan vs realization in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055559#M160945</link>
    <description>&lt;P&gt;Dear&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;you were correct. Solution offered by&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="625922" data-lia-user-login="bhanu_gautam" class="lia-mention lia-mention-user"&gt;bhanu_gautam&lt;/a&gt;&amp;nbsp; is something i already tried and i get all counted. Anyway, yours is closer but i would need that calculaton respects one filter more: Cycle. As in plan we have cycle 1 or 2 for same account (1st half a year or 2nd half) it should respect it as now it sums cycle and 2! But i am closer &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 23 Jul 2024 06:23:42 GMT</pubDate>
    <dc:creator>al1981</dc:creator>
    <dc:date>2024-07-23T06:23:42Z</dc:date>
    <item>
      <title>Plan vs realization</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4054680#M160908</link>
      <description>&lt;P&gt;I would like to do some analytics on activities of our sales rep... I think its pretty basic, but...&lt;/P&gt;&lt;P&gt;I have one table with historical data (contacts with buyers and product details, dates, location, …) and few dimension tables like Date, Channel, Product and also buyer with segmentation (importance) and sales rep unique link&lt;/P&gt;&lt;P&gt;I succeed to create measures for Coverage, Month over month change, week over week, but I am facing issue where I would like to present in same pivot:&lt;BR /&gt;- plan vs realization (activities)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;What would be best way to do? I don't have issues with calucations on historical data, but with data on plan and to show the realisation... If anyone can help with some idea... Please let me know if I should make something more clear...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;!--  StartFragment   --&gt;&lt;SPAN class=""&gt;this works well - Coverage:=&lt;/SPAN&gt;&lt;SPAN class=""&gt;DISTINCTCOUNT&lt;/SPAN&gt;&lt;SPAN class=""&gt;(Activities[Unique link])/&lt;/SPAN&gt;&lt;SPAN class=""&gt;COUNTA&lt;/SPAN&gt;&lt;SPAN class=""&gt;(Plan[Unique link]) - i can create pivot by sales rep in rows,&amp;nbsp;&lt;/SPAN&gt;&lt;!--  EndFragment   --&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;but if i create another measure like&amp;nbsp;&lt;!--  StartFragment   --&gt;Plan:=&lt;SPAN class=""&gt;COUNTA&lt;/SPAN&gt;(Plan[Unique link]) i get full counting and not per sales rep like i get coverage... clearly i need measure respecting row filter...?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;img /&gt;&lt;!--  EndFragment   --&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jul 2024 21:35:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4054680#M160908</guid>
      <dc:creator>al1981</dc:creator>
      <dc:date>2024-07-22T21:35:00Z</dc:date>
    </item>
    <item>
      <title>Re: Plan vs realization</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055332#M160934</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="523197" data-lia-user-login="al1981" class="lia-mention lia-mention-user"&gt;al1981&lt;/a&gt;&amp;nbsp;, You have already created one measure for coverage now you can create two more measure for Plan and Realization using calculate and ALLexcept function&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Plan = &lt;BR /&gt;CALCULATE(&lt;BR /&gt;COUNTA(Plan[Unique link]), &lt;BR /&gt;ALLEXCEPT(Plan, Plan[Sales Rep])&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Realization = &lt;BR /&gt;CALCULATE(&lt;BR /&gt;COUNTA(Activities[Unique link]), &lt;BR /&gt;ALLEXCEPT(Activities, Activities[Sales Rep])&lt;BR /&gt;)&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jul 2024 04:42:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055332#M160934</guid>
      <dc:creator>bhanu_gautam</dc:creator>
      <dc:date>2024-07-23T04:42:48Z</dc:date>
    </item>
    <item>
      <title>Re: Plan vs realization</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055461#M160940</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="523197" data-lia-user-login="al1981" class="lia-mention lia-mention-user"&gt;al1981&lt;/a&gt;&amp;nbsp;，&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thank you&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="625922" data-lia-user-login="bhanu_gautam" class="lia-mention lia-mention-user"&gt;bhanu_gautam&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;very much for the solution, and&amp;nbsp;I've tried other ways to help you understand the problem:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;According to your requirement, I think you are counting the plan will show all the counts, according to the data you gave which is 4,&lt;/P&gt;
&lt;P&gt;but you want to count the sales reps individually according to their plan, here is my idea to realize it, maybe it can help you to solve the problem.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;PlanCount = SUMX(VALUES('Plan'[Sales Rep]), CALCULATE(COUNTROWS('Plan'),FILTER(ALL('Plan'),Plan[Sales Rep]=MAX('Plan'[Sales Rep]))))&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;ActivityCount = SUMX(VALUES(Activities[Sales Rep]),CALCULATE(COUNTROWS('Activities'),FILTER(ALL('Activities'),'Activities'[Sales Rep]=MAX(Activities[Sales Rep]))))&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;PlanVsActivity = [ActivityCount]-[PlanCount] &lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Hope it helps!&lt;/P&gt;
&lt;P&gt;Best regards,&lt;BR /&gt;Community Support Team_ Tom Shen&lt;/P&gt;
&lt;P&gt;If this post helps then please consider&amp;nbsp;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jul 2024 05:52:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055461#M160940</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-07-23T05:52:11Z</dc:date>
    </item>
    <item>
      <title>Re: Plan vs realization</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055559#M160945</link>
      <description>&lt;P&gt;Dear&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;you were correct. Solution offered by&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="625922" data-lia-user-login="bhanu_gautam" class="lia-mention lia-mention-user"&gt;bhanu_gautam&lt;/a&gt;&amp;nbsp; is something i already tried and i get all counted. Anyway, yours is closer but i would need that calculaton respects one filter more: Cycle. As in plan we have cycle 1 or 2 for same account (1st half a year or 2nd half) it should respect it as now it sums cycle and 2! But i am closer &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jul 2024 06:23:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4055559#M160945</guid>
      <dc:creator>al1981</dc:creator>
      <dc:date>2024-07-23T06:23:42Z</dc:date>
    </item>
    <item>
      <title>Re: Plan vs realization</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4056053#M160962</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="523197" data-lia-user-login="al1981" class="lia-mention lia-mention-user"&gt;al1981&lt;/a&gt;&amp;nbsp;，&lt;/P&gt;
&lt;P&gt;If we add loops as a filter with salesperson as the filter, then we can make some changes to the original DAX.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;PlanCount = CALCULATE
(COUNTROWS('Plan'),
ALLEXCEPT(Plan,'Plan'[Cycle],'Plan'[Sales Rep]))&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;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope it helps!&lt;/P&gt;
&lt;P&gt;Best regards,&lt;BR /&gt;Community Support Team_ Tom Shen&lt;/P&gt;
&lt;P&gt;If this post helps then please consider&amp;nbsp;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jul 2024 09:33:30 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Plan-vs-realization/m-p/4056053#M160962</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-07-23T09:33:30Z</dc:date>
    </item>
  </channel>
</rss>

