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
Kenmare
Frequent Visitor

Count values which can be on two different columns

Hi there !

I'm creating a dashboard to study each strategy for a football team with these tables :

Kenmare_0-1697451326745.png

 

 

In my report: a slicer to select a team.
I want to display, for each strategy, how many times it has been used by a team.
Example for team 1:
4-4-2 --> 3
4-3-3 --> 3
3-5-2 --> 2

I created a table chart with Strategy Name and a measure with a countx for each Team_1_strategy_id or Team_2_strategy_id (because a team can be home or visitor) but it doesn't work.
Do you know if it's possible in PowerBI or I'm wasting my time ?

Thank you !

1 ACCEPTED SOLUTION
5 REPLIES 5
Kenmare
Frequent Visitor

Thank you @Ahmedx this is what I was searching for this visual.

@Anonymous the logic was to calculate the number of occurrences of each strategy: if the team plays at home (in team_1_id) + away (in team_2_id)

Anonymous
Not applicable

Hi @Kenmare ,

I'm a little confused about your needs, Could you please explain them further? It would be good to provide a screenshot of the results you are expecting and desensitized example data.

Thanks for your efforts & time in advance.

 

Best regards,
Community Support Team_Binbin Yu

Hi @Anonymous 

 

Thank you for your answer. I'll try to explain no problem.

I put my example in the attached power pi file: https://1drv.ms/u/s!AoMg4cU4jocGpm2dOeYuSNkgKKw0?e=3iTrKT 

Here is a screenshot of the resultats expected : for a selected team, having the count of each strategy used :

Kenmare_0-1697702078775.png

Best regards.

Kenmare

Anonymous
Not applicable

Hi @Kenmare ,

Could you please provide the calculate logic? 

vbinbinyumsft_0-1697709215581.png

vbinbinyumsft_1-1697709292627.png

 

Best regards,
Community Support Team_Binbin Yu

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!

November Carousel

Fabric Community Update - November 2024

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

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.