This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hi,
Good day to all,
I have been trying to create a measure to calculate number of repeated customers. To use in a matrix to filter for number repeated for each Item ID. I have used methods mentioned in the following links & been unfortunetly unsuccessful to get the accurate numbers confirmed using excel
count if $>0 (using pivot --> Num of orders: ([Rows: Item_ID, Customer_ID] [Columns: dates] [values: bookings_$]))
then ( # Reorder: sumifs # num of orders > 1 for each Item_ID)
I have included a sample of the data similar to dataset used.
The page is filtered for Bookings Only.
No date restriction.
https://p3adaptive.com/2014/12/repeat-customers-in-dax-three-flavors/
https://www.daxpatterns.com/new-and-returning-customers/
Booking Table
| Customer ID | Date | Order ID | Shipping or bookeding | Item ID | Unit | $ | Net Vs Gross |
| Brook_J | 02/13/2020 | Brook_J02/13/2020 | Booking | Z2345 | 5 | 15 | Gross |
| John_A | 03/25/2020 | John_A03/25/2020 | Booking | E2525 | 10 | 30 | Gross |
| Alice_M | 05/30/2021 | Alice_M05/30/2021 | Booking | M4045 | 8 | 40 | Gross |
| Michael_T | 10/17/2021 | Michael_T05/30/2021 | Booking | G6065 | 3 | 25 | Gross |
| John_A | 06/30/2020 | John_J06/30/2020 | Shipping | E2525 | -10 | -30 | Cancellation |
| Brook_J | 05/20/2020 | Shipping | Z2345 | 5 | 15 | Gross | |
| Alice_M | 10/15/2021 | Shipping | ZM4045 | 8 | 40 | Groos | |
| Michael_T | 12/30/2021 | Michael_T12/30/2021 | Shipping | G6065 | -3 | -25 | Cancellation |
| Caroline_D | 05/25/2022 | Caroline_D05/25/2022 | Booking | F9915 | 5 | 50 | Gross |
| Caroline_D | 10/20/2022 | Shipping | F9915 | 5 | 50 | Gross | |
| Alice_M | 01/25/2022 | Alice_M08/25/2022 | Booking | Z2345 | 20 | 60 | Gross |
| John_A | 04/20/2022 | John_A04/20/2022 | Booking | G6065 | 10 | 30 | Gross |
| Alice_M | 04/20/2022 | Shipping | Z2345 | 20 | 60 | Groos |
Date Table
| Date | Month | Year |
| 01/01/2020 | Jan | 2020 |
| 01/02/2020 | Jan | 2020 |
| 01/03/2020 | Jan | 2020 |
| 01/04/2020 | Jan | 2020 |
Customer info Table
| Customer ID | City | Country | Name | Last Name |
| Brooke_j | Washington | US | Brooke | Janin |
| John_A | Los Angeles | US | John | Abraham |
| Alice_M | Miami | US | Alice | Morphy |
| Michael_T | Texas | US | Michael | tenant |
| Caroline_D | Torotno | CA | Carolin | Donway |
@ssaadat , in this blog, refer repeat and use customer and item inside summarize
example
Retained Customer This Month = sumx(summarize(Sales, Customer[Customer], Item[Item]), if(not(ISBLANK([MTD])) && not(ISBLANK([LMTD])) , 1,BLANK()))
Customer Retention Part 1:
https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-1-Month-on-Month-Retention/b...
Customer Retention Part 2: Period over Period Retention :https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-2-Period-over-Period-Retenti...
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.