Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
AlanP514
Helper V
Helper V

Conditional Dynamic Dax Segregation on customer

Hi All ,
I am expecting Help on this to achive this logic
I need to segregate user into three categories
Active Customer, Super Active Customer,Hyper Active Customer

Based on the year and month selection applying  in the power bi report 
customer segregation should happen

I have two slicers one is Year, and Month  Based on the these selection my power bi pivot table will work dynamically from selected month to last 6 months for eg (I am selecting September 2023 from slicer my power bi pivot table will work from septmber to April)
Diagram :1 
AlanP514_1-1695983018662.png
I need to segregate customer based on the above pivot table into Active Customer, Super Active Customer,Hyper Active Customer
For these need consider these conditions

1 . Active Customer =  if the Count of Login time is greater than equal to 1 for the entire selected 6 months and if minimum value is (1 ,2)then that user is active customer
2. Super Active Customer =  if the Count of Login time is greater than equal to 3 for the entire selected 6 months and if minimum value is 3 or 4 then that user is Super active Customer
3.Hyper Active Customer =  if the Count of Login time is greater than equal to 5 for the entire selected 6 months and if minimum value is 5 then that user is Hyper active Customer

image - 2.png
I am attaching the data model also here
data model.png

This is the data model dynamic month name is coming from Previous date calendar table and month slicer is coming from Calendar table and user id and login is coming from fact tracking table
Appreciate Help on this to achive the logic 

10 REPLIES 10
Ashish_Mathur
Super User
Super User

Hi,

Why has UserID 300004579 been classified as "Super Active Customer"?  The minimum login value of this customer is 1,2.  Share raw data in a format that can be pasted in an MS Excel file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hi @Ashish_Mathur ,
I hope you are clear with query, Kindly let me know if you have doubt still
Regards
Alan 

I suggest you start a new thread.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hi   @Ashish_Mathur 
,yes as u said the customer  300004579 should be active customer only, i mistakenly mapped to super active customer, 
i am attaching segregation conditon, kindly have a look and let me know if you have any queries , and please provide solution 


1 . Active Customer =  if the Count of Login time is greater than equal to 1 for the entire selected 6 months and if minimum value is (1 ,2)then that user is active customer
2. Super Active Customer =  if the Count of Login time is greater than equal to 3 for the entire selected 6 months and if minimum value is 3 or 4 then that user is Super active Customer
3.Hyper Active Customer =  if the Count of Login time is greater than equal to 5 for the entire selected 6 months and if minimum value is 5 then that user is Hyper active Customer

Regards,
Alan P James
https://www.linkedin.com/in/alan-p-james-76b6aa16a/




@Ashish_Mathur

Hai @Ashish_Mathur 
As you said i am pasting mock data
Please find attached excel sheet , and please let me know the solution for achiving this customer segmentation based on the selection

Since you have still not clarifies my previous doubt (asked yesterday), even if i download the file, i will not be able to help you.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

Hi @Ashish_Mathur 

Yes, As you mentioned the user 300004579

Is should be in active customer not in super active because the minimum value is 1 

 

Kindly have a look on the Excel sheet which I attached as mock data aswell as the logic 

It would be great if you could provide solution on this

 

 

Regards

Alan p

Anonymous
Not applicable

Hai @Ashish_Mathur 

Customer 300004579 login count is greater than 3 and if the minimum value is 3 or 4 for selected 6 months

Then that customer should be super active customer

So based on this condition I can say mentioned customer is super active , we can categorise while seeing login count of this user's data

 

I will provide you the sample data of this

But big thanks @Ashish_Mathur  your response

I will provide you the data

You are welcome.  I am confused.  For that customer, the minimum count is 1 and therefore he should be Active not Super Active.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
lbendlin
Super User
Super User

Please provide sample data (with sensitive information removed) that covers your issue or question completely, in a usable format (not as a screenshot). Leave out anything not related to the issue.
If you are unsure how to do that please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.

If you want to get answers faster please refer to https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.