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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Francease04
New Member

Customer Segmentation

I have this column formula as my slicer for my segmentation but it is not working properly.

UAP means Bet > 0
w/ Deposit means Deposit > 0
w/ Bonus means Bonus > 0

The Segmentation Slicer

Francease04_0-1732013756544.png

Table Relationship

Francease04_1-1732013968568.pngFrancease04_2-1732013992097.png

Sample Table
Francease04_3-1732014196254.png


Player  = public register customer_name (default column)
Bet = All Games FilteredBet (dax column)
Deposit = public register CRM DEPOSIT AMOUNT (dax measure)
Bonus = public register CRM BONUS AMOUNT (dax measure)

Francease04_4-1732014440173.png

Francease04_5-1732014462606.png

Francease04_6-1732014487919.png

Francease04_7-1732014554688.png


I don't know if the problem is in the relationship table or the formula's I used because when I'm selecting a slicer it does not give me the correct result.

Can someone help me?

 

1 ACCEPTED SOLUTION
Poojara_D12
Super User
Super User

Hi @Francease04 

 

To address the issue you're facing with your segmentation slicer not working properly, let's take a systematic approach:


1. Understand the Expected Behavior of Your Segmentation

Your slicer categorizes players into the following segments based on these conditions:

  • UAP: Bet > 0
  • w/ Deposit: Deposit > 0
  • w/ Bonus: Bonus > 0

The slicer should properly filter the data in your visualizations.


2. Potential Issues to Check

The issue might arise from:

  1. Relationships in the Model: Ensure proper relationships are established between your tables (e.g., "Player Table" and "Transactions Table").
  2. DAX Logic for Columns/Measures: Verify the formulas you're using for the slicer and segmentation.
  3. Data Granularity: Ensure the tables you're working with align on a common granularity, such as Player.

3. Verify Table Relationships

From the screenshots (or descriptions of your model), confirm these:

  • Primary Table: You are likely using a "Player" table that includes customer names or IDs as the key.
  • Transactions Table: This table contains Bet, Deposit, and Bonus information.
  • Relationships should be one-to-many or many-to-one as follows:
    • Player Table[PlayerID] → Transactions Table[PlayerID]

4. Correct DAX for Your Columns

Use calculated columns to segment players based on their Bet, Deposit, and Bonus values.

DAX for Segmentation (Calculated Column)

Create a new calculated column in the Player Table to segment players:

 

 

Segmentation =
SWITCH(
    TRUE(),
    [Bet] > 0, "UAP",
    [Deposit] > 0, "w/ Deposit",
    [Bonus] > 0, "w/ Bonus",
    "No Activity"
)

 

 

This column categorizes players based on their first matching condition.


5. Alternative: Use Measures for Granularity

If the Bet, Deposit, and Bonus are calculated using measures, you cannot directly use them in a calculated column. Instead, create a Segmentation Measure:

 

Segmentation Measure =
SWITCH(
    TRUE(),
    MAX('Transactions Table'[Bet]) > 0, "UAP",
    MAX('Transactions Table'[Deposit]) > 0, "w/ Deposit",
    MAX('Transactions Table'[Bonus]) > 0, "w/ Bonus",
    "No Activity"
)

 

Add this measure to your slicer visual. Power BI supports measures as slicer inputs since it dynamically computes based on the visual context.


6. Check Slicer Configuration

Ensure that your slicer is set up properly:

  1. Add the Segmentation column (or measure) to the slicer visual.
  2. Set the slicer to filter all visuals properly.

7. Verify Filter Behavior

  • Select one segmentation option in the slicer and observe if it filters the table/visual correctly.
  • If it doesn't work:
    • Recheck your relationships.
    • Ensure the Bet, Deposit, and Bonus values are correctly aggregated.

8. Debugging Tips

If the slicer still behaves incorrectly:

  1. Use a table visual to display Player, Bet, Deposit, and Bonus side-by-side with Segmentation. This helps verify that your DAX logic and relationships are correct.
  2. Check if the slicer is filtering the expected field (e.g., Player).

 

  • Ensure Consistent Granularity: If the "Transactions" table contains multiple rows per player, aggregate the data (e.g., SUM, MAX) at the player level before applying segmentation.
  • Avoid Duplicates: Ensure the relationships don't introduce duplicate data for players.

 

Did I answer your question? Mark my post as a solution, this will help others!

If my response(s) assisted you in any way, don't forget to drop me a "Kudos" 🙂

Kind Regards,
Poojara
Data Analyst | MSBI Developer | Power BI Consultant
YouTube: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

Did I answer your question? Mark my post as a solution, this will help others!
If my response(s) assisted you in any way, don't forget to drop me a "Kudos"

Kind Regards,
Poojara - Proud to be a Super User
Data Analyst | MSBI Developer | Power BI Consultant
Consider Subscribing my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

View solution in original post

1 REPLY 1
Poojara_D12
Super User
Super User

Hi @Francease04 

 

To address the issue you're facing with your segmentation slicer not working properly, let's take a systematic approach:


1. Understand the Expected Behavior of Your Segmentation

Your slicer categorizes players into the following segments based on these conditions:

  • UAP: Bet > 0
  • w/ Deposit: Deposit > 0
  • w/ Bonus: Bonus > 0

The slicer should properly filter the data in your visualizations.


2. Potential Issues to Check

The issue might arise from:

  1. Relationships in the Model: Ensure proper relationships are established between your tables (e.g., "Player Table" and "Transactions Table").
  2. DAX Logic for Columns/Measures: Verify the formulas you're using for the slicer and segmentation.
  3. Data Granularity: Ensure the tables you're working with align on a common granularity, such as Player.

3. Verify Table Relationships

From the screenshots (or descriptions of your model), confirm these:

  • Primary Table: You are likely using a "Player" table that includes customer names or IDs as the key.
  • Transactions Table: This table contains Bet, Deposit, and Bonus information.
  • Relationships should be one-to-many or many-to-one as follows:
    • Player Table[PlayerID] → Transactions Table[PlayerID]

4. Correct DAX for Your Columns

Use calculated columns to segment players based on their Bet, Deposit, and Bonus values.

DAX for Segmentation (Calculated Column)

Create a new calculated column in the Player Table to segment players:

 

 

Segmentation =
SWITCH(
    TRUE(),
    [Bet] > 0, "UAP",
    [Deposit] > 0, "w/ Deposit",
    [Bonus] > 0, "w/ Bonus",
    "No Activity"
)

 

 

This column categorizes players based on their first matching condition.


5. Alternative: Use Measures for Granularity

If the Bet, Deposit, and Bonus are calculated using measures, you cannot directly use them in a calculated column. Instead, create a Segmentation Measure:

 

Segmentation Measure =
SWITCH(
    TRUE(),
    MAX('Transactions Table'[Bet]) > 0, "UAP",
    MAX('Transactions Table'[Deposit]) > 0, "w/ Deposit",
    MAX('Transactions Table'[Bonus]) > 0, "w/ Bonus",
    "No Activity"
)

 

Add this measure to your slicer visual. Power BI supports measures as slicer inputs since it dynamically computes based on the visual context.


6. Check Slicer Configuration

Ensure that your slicer is set up properly:

  1. Add the Segmentation column (or measure) to the slicer visual.
  2. Set the slicer to filter all visuals properly.

7. Verify Filter Behavior

  • Select one segmentation option in the slicer and observe if it filters the table/visual correctly.
  • If it doesn't work:
    • Recheck your relationships.
    • Ensure the Bet, Deposit, and Bonus values are correctly aggregated.

8. Debugging Tips

If the slicer still behaves incorrectly:

  1. Use a table visual to display Player, Bet, Deposit, and Bonus side-by-side with Segmentation. This helps verify that your DAX logic and relationships are correct.
  2. Check if the slicer is filtering the expected field (e.g., Player).

 

  • Ensure Consistent Granularity: If the "Transactions" table contains multiple rows per player, aggregate the data (e.g., SUM, MAX) at the player level before applying segmentation.
  • Avoid Duplicates: Ensure the relationships don't introduce duplicate data for players.

 

Did I answer your question? Mark my post as a solution, this will help others!

If my response(s) assisted you in any way, don't forget to drop me a "Kudos" 🙂

Kind Regards,
Poojara
Data Analyst | MSBI Developer | Power BI Consultant
YouTube: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

Did I answer your question? Mark my post as a solution, this will help others!
If my response(s) assisted you in any way, don't forget to drop me a "Kudos"

Kind Regards,
Poojara - Proud to be a Super User
Data Analyst | MSBI Developer | Power BI Consultant
Consider Subscribing my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.