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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
AlanP514
Helper V
Helper V

Conditional group dax

Pivot TablePivot Table

I am trying to create conditional group or bin based on the measure 
I need to segragte all customer into three
Hyper active 
Super Active
Active
I Have created count of user who has logged in each month(Below is that measure)

Logins = Sumx(Facttracking, Fact tracking[Desktop count] +  Fact tracking[Mobile count]

so i have added user in the row section of the pivot , month in the section of column name and login in the measure value
so according to the sum of all values aganist each month
if the total sum of the count value  >= 5 i need to segregrate those customer into hyper active
if the total sum of the count value  = 3,4 i need to segregrate those customer into Super  active
if the total sum of the count value  = 1,2 i need to segregrate those customer into   active




Appreatiate help on this to create dax

 

2 REPLIES 2
AlanP514
Helper V
Helper V

Hi @nirali_arora 
Thanks for the answer and help, there is a small logic difference is in the logic
i wanted to make the segregation aganist user if login value is greater  than five then hyper active but this should work if value should be greater than 5 for entire month then only the user will be hyper active custromer

nirali_arora
Resolver II
Resolver II

You can try the following measure

CustomerCategory =

VAR TotalLogins = [Logins]

RETURN

SWITCH ( TRUE (),

TotalLogins >= 5, "Hyper Active",

TotalLogins >= 3 &&

TotalLogins <= 4, "Super Active",

TotalLogins >= 1 &&

TotalLogins <= 2, "Active",

BLANK ()

)

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Carousel June 2024

Check out the June 2024 Power BI update to learn about new features.

2
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.