<?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: Measure to show current, new, recovered and lost buyers of the quarter in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3057115#M105498</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="477226" data-lia-user-login="Laocsulak" class="lia-mention lia-mention-user"&gt;Laocsulak&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can refer to the following measures.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Buyers of the previous quarter = CALCULATE(DISTINCTCOUNT(transactions[payer_id]),ALL(transactions),transactions[quarter]=MAX([quarter])-1)

Lost buyers of the current quarter = var _lastquartercustomer=SUMMARIZE(FILTER(ALL(transactions),[quarter]=MAX([quarter])-1),[payer_id])
return COUNTROWS(FILTER(_lastquartercustomer,[payer_id] in VALUES(transactions[payer_id])=FALSE()))

Recovered buyers of the quarter = var _lastquartercustomer=SUMMARIZE(FILTER(ALL(transactions),[quarter]=MAX([quarter])-1),[payer_id])
return CALCULATE(DISTINCTCOUNT(transactions[payer_id]),FILTER(transactions,transactions[trx_merchant_asc]&amp;lt;&amp;gt;1&amp;amp;&amp;amp;[payer_id] in _lastquartercustomer =FALSE()))&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards!&lt;/P&gt;
&lt;P&gt;Yolo Zhu&lt;/P&gt;
&lt;P&gt;If this post&amp;nbsp;&lt;I&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/I&gt;, then please consider&amp;nbsp;&lt;I&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/I&gt;&amp;nbsp;to help the other members find it more quickly&lt;/P&gt;</description>
    <pubDate>Thu, 02 Feb 2023 07:31:57 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2023-02-02T07:31:57Z</dc:date>
    <item>
      <title>Measure to show current, new, recovered and lost buyers of the quarter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3056058#M105427</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I have created the next table to explain the measures I need to create:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to create the next 5 measures, where I mention the value that it would take if I would be filtering the quarter 4.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Buyers of the current quarter: 5&lt;/STRONG&gt;.&amp;nbsp;Because there were 5 different buyers in the quarter 4: buyers 1, 2, 3, 4 and 7&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;New Buyers of the quarter: 1&lt;/STRONG&gt;. Because there was only one new buyer in the quarter 4: buyer 7&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Buyers of the previous quarter: 3&lt;/STRONG&gt;. Because there were 3 different buyers in the quarter 4: buyers 4, 5 and 6&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Recovered buyers of the quarter: 3&lt;/STRONG&gt;. This express the buyers that bought in the current quarter, and they didn't buy in the previous quarter, but they have bought in some previous quarter. These are the buyers 1, 2 and 3 who bought in quarter 2, not in quarter 3, and bought again in quarter 4.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Lost buyers of the current quarter: 2&lt;/STRONG&gt;. This express the buyers that bought in the last quarter, but not in the current quarter. These are the buyers 5 and 6 that bought in quarter 3 but not in quarter 4.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have created this model where I could create the &lt;STRONG&gt;Buyers of the current quarter &lt;/STRONG&gt;and the&amp;nbsp;&lt;STRONG&gt;New Buyers of the quarter&lt;/STRONG&gt; measures, but not the last three:&lt;/P&gt;&lt;P&gt;&lt;A href="https://drive.google.com/drive/folders/1A1lQk9UhC25q1rBgD-dIo1kdEi1FfDbL?usp=sharing" target="_blank"&gt;https://drive.google.com/drive/folders/1A1lQk9UhC25q1rBgD-dIo1kdEi1FfDbL?usp=sharing&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What's the best way to create these measures? Thanks in advance!&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 19:48:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3056058#M105427</guid>
      <dc:creator>Laocsulak</dc:creator>
      <dc:date>2023-02-01T19:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: Measure to show current, new, recovered and lost buyers of the quarter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3056595#M105457</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="477226" data-lia-user-login="Laocsulak" class="lia-mention lia-mention-user"&gt;Laocsulak&lt;/a&gt; , You have to follow the approach of customer retention &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Customer Retention Part 1:&lt;BR /&gt;&lt;A href="https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-1-Month-on-Month-Retention/ba-p/1361529" target="_blank"&gt;https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-1-Month-on-Month-Retention/ba-p/1361529&lt;/A&gt;&lt;BR /&gt;Customer Retention Part 2: Period over Period Retention:&lt;A href="https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-2-Period-over-Period-Retention/ba-p/1377458" target="_blank"&gt;https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-2-Period-over-Period-Retention/ba-p/1377458&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You just have to change period&lt;/P&gt;
&lt;P&gt;Time Intelligence, Part of learn Power BI &lt;A href="https://youtu.be/cN8AO3_vmlY?t=27510" target="_blank"&gt;https://youtu.be/cN8AO3_vmlY?t=27510&lt;/A&gt;&lt;BR /&gt;Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period, &lt;BR /&gt;Custom Period till date: &lt;A href="https://youtu.be/aU2aKbnHuWs&amp;amp;t=145s" target="_blank"&gt;https://youtu.be/aU2aKbnHuWs&amp;amp;t=145s&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Feb 2023 02:18:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3056595#M105457</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2023-02-02T02:18:58Z</dc:date>
    </item>
    <item>
      <title>Re: Measure to show current, new, recovered and lost buyers of the quarter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3057115#M105498</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="477226" data-lia-user-login="Laocsulak" class="lia-mention lia-mention-user"&gt;Laocsulak&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can refer to the following measures.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Buyers of the previous quarter = CALCULATE(DISTINCTCOUNT(transactions[payer_id]),ALL(transactions),transactions[quarter]=MAX([quarter])-1)

Lost buyers of the current quarter = var _lastquartercustomer=SUMMARIZE(FILTER(ALL(transactions),[quarter]=MAX([quarter])-1),[payer_id])
return COUNTROWS(FILTER(_lastquartercustomer,[payer_id] in VALUES(transactions[payer_id])=FALSE()))

Recovered buyers of the quarter = var _lastquartercustomer=SUMMARIZE(FILTER(ALL(transactions),[quarter]=MAX([quarter])-1),[payer_id])
return CALCULATE(DISTINCTCOUNT(transactions[payer_id]),FILTER(transactions,transactions[trx_merchant_asc]&amp;lt;&amp;gt;1&amp;amp;&amp;amp;[payer_id] in _lastquartercustomer =FALSE()))&lt;/LI-CODE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards!&lt;/P&gt;
&lt;P&gt;Yolo Zhu&lt;/P&gt;
&lt;P&gt;If this post&amp;nbsp;&lt;I&gt;&lt;STRONG&gt;helps&lt;/STRONG&gt;&lt;/I&gt;, then please consider&amp;nbsp;&lt;I&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/I&gt;&amp;nbsp;to help the other members find it more quickly&lt;/P&gt;</description>
      <pubDate>Thu, 02 Feb 2023 07:31:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3057115#M105498</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-02-02T07:31:57Z</dc:date>
    </item>
    <item>
      <title>Re: Measure to show current, new, recovered and lost buyers of the quarter</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3058963#M105611</link>
      <description>&lt;P&gt;It worked, thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Feb 2023 21:01:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-to-show-current-new-recovered-and-lost-buyers-of-the/m-p/3058963#M105611</guid>
      <dc:creator>Laocsulak</dc:creator>
      <dc:date>2023-02-02T21:01:55Z</dc:date>
    </item>
  </channel>
</rss>

