Forum Discussion
Show Two Lines on the same Chart from same Column in Power BI Desktop
I was trying to show two values from a same column on the same Lines Chart, but cant find a simple way to do it.
I have a Table like this:
DateTeamValue
| 01/02/2023 | Team 1 | 0 |
| 03/02/2023 | Team 1 | 30 |
| 11/02/2023 | Team 1 | 45 |
| 15/02/2023 | Team 1 | 15 |
| 02/02/2023 | Team 2 | 6 |
| 05/02/2023 | Team 2 | 18 |
| 11/02/2023 | Team 2 | 0 |
| 16/02/2023 | Team 2 | 37 |
I'm trying to show Team 1 and Team 2 in two different Lines on the chart, and on X axis the Dates (and add a slide). It looks like this:
If I add a filter it shows only one, and the only way I found to solve it is create two New Columns in Power Query (the first only shows the Values from Team 1 and the Second only from Team 2).
Is there another way to solve it?
Thanks
Hi Anonymous
You can achieve your goals in 2 ways :1. just put your team to a legend :
2 create measures for every team, like :Total team 1 = CALCULATE(sum('Table'[Value]),'Table'[Team]= "team 1")Total team 2 = CALCULATE(sum('Table'[Value]),'Table'[Team]= "team 2")and than put both of your measures on Y axis:
Please consider Accepting it as the solution to help the other members find it more quickly
2 Replies
- Ritaf1983
Super User
Hi Anonymous
You can achieve your goals in 2 ways :1. just put your team to a legend :
2 create measures for every team, like :Total team 1 = CALCULATE(sum('Table'[Value]),'Table'[Team]= "team 1")Total team 2 = CALCULATE(sum('Table'[Value]),'Table'[Team]= "team 2")and than put both of your measures on Y axis:
Please consider Accepting it as the solution to help the other members find it more quickly
- Ashish_Mathur
Super User
Hi,
What happens when you drag Team to the legend?