<?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: Count orders of customer and create segment in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182176#M18470</link>
    <description>&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you have a solution with a formula for measures? like summarize and group by?&lt;/P&gt;</description>
    <pubDate>Thu, 25 Jun 2020 11:15:12 GMT</pubDate>
    <dc:creator>clarissa</dc:creator>
    <dc:date>2020-06-25T11:15:12Z</dc:date>
    <item>
      <title>Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1181543#M18454</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have customer-email adresses and order numbers as different columns. I'd like to calculate the number of orders per customer-email and then create a separate column "segment" based on the number of orders.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;The table should be able to show segments with then the connected net sales (same table).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to achieve this?&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 07:58:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1181543#M18454</guid>
      <dc:creator>clarissa</dc:creator>
      <dc:date>2020-06-25T07:58:12Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1181739#M18457</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236631" data-lia-user-login="clarissa" class="lia-mention lia-mention-user"&gt;clarissa&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can try something like this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://radacad.com/customers-grouped-by-count-of-their-orders-static-segmentation-in-power-bi" target="_blank"&gt;https://radacad.com/customers-grouped-by-count-of-their-orders-static-segmentation-in-power-bi&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;Do share sample data incase this does not work.&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 08:45:22 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1181739#M18457</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T08:45:22Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182176#M18470</link>
      <description>&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you have a solution with a formula for measures? like summarize and group by?&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:15:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182176#M18470</guid>
      <dc:creator>clarissa</dc:creator>
      <dc:date>2020-06-25T11:15:12Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182180#M18471</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236631" data-lia-user-login="clarissa" class="lia-mention lia-mention-user"&gt;clarissa&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please share sample data and the expected output te help you on this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;HN&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:16:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182180#M18471</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T11:16:29Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182189#M18473</link>
      <description>&lt;P&gt;ok&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have the following data:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;email cst.&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;order_no&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;......&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; abc&lt;/P&gt;&lt;P&gt;......&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; efg&lt;/P&gt;&lt;P&gt;........&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; hijk&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- I need to count the distinct order-No per e-mail cst&lt;/P&gt;&lt;P&gt;- I need an addition column to create segments based on number of orders, such as:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Segment = IF(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DISTINCTCOUNT(sales[order_no]) = 1, &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"new",&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;IF(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DISTINCTCOUNT(sales[order_no]) = 2, &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"repeat",&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"loyal")&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;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;- I need to be able to show the values by segment&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does that help?&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:19:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182189#M18473</guid>
      <dc:creator>clarissa</dc:creator>
      <dc:date>2020-06-25T11:19:38Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182205#M18475</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236631" data-lia-user-login="clarissa" class="lia-mention lia-mention-user"&gt;clarissa&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do Emails repaeat in you tble ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you share some 10 like of sample?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;HN&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:29:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182205#M18475</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T11:29:59Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182218#M18476</link>
      <description>&lt;P&gt;Unfortunately I can't share the table, but the email is also not unique... so an e-mail address can come up a few times with different order numbers... can you work with this?&amp;nbsp; Thank you so much&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:34:06 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182218#M18476</guid>
      <dc:creator>clarissa</dc:creator>
      <dc:date>2020-06-25T11:34:06Z</dc:date>
    </item>
    <item>
      <title>Re: Count orders of customer and create segment</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182253#M18478</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="236631" data-lia-user-login="clarissa" class="lia-mention lia-mention-user"&gt;clarissa&lt;/a&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;&lt;img /&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;&lt;STRONG&gt;Create a measure&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DC = CALCULATE(DISTINCTCOUNT('Table'[Order No]),ALLEXCEPT('Table','Table'[email]))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;STRONG&gt;Then create a New Table&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Seg = &lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;ADDCOLUMNS(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;SUMMARIZE(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;'Table',&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;'Table'[email],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"Distinct_", [DC]),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"Segment", &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;SWITCH(&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;TRUE(),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;[Distinct_] = 1, "New",&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;[Distinct_] = 2, "Repeat",&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;"Loyal"&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;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;Regards,&lt;BR /&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;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 25 Jun 2020 11:46:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-orders-of-customer-and-create-segment/m-p/1182253#M18478</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-06-25T11:46:09Z</dc:date>
    </item>
  </channel>
</rss>

