Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi Experts,
Suppose we have region and city and a user selected filter by region.
If user chose one single region, there is a monthly trend line chart by city.( cities for each line by selected single region)
If user chose all or multiple region, there is a monthly trend line chart by region.(regions for each line)
Anyone can help?
Best Regards
Bruce Chen
Solved! Go to Solution.
Hi @Anonymous ,
We can create a calculated table to work on it. One sample for your reference. Please check the following steps as below.
1. Create a calculated table and make it related to the fact table.
di = UNION(VALUES('Table'[city]),VALUES('Table'[region]))
2. Then we can create a measure as below to get the excepted result as we need.
Measure = IF ( ISFILTERED ( 'Table'[city] ), SUM ( 'Table'[amount] ), IF ( ISFILTERED ( 'Table'[region] ), CALCULATE ( SUM ( 'Table'[amount] ), USERELATIONSHIP ( di[city / region], 'Table'[region] ) ) ) )
BTW, pbix as attached.
Hi @Anonymous ,
We can create a calculated table to work on it. One sample for your reference. Please check the following steps as below.
1. Create a calculated table and make it related to the fact table.
di = UNION(VALUES('Table'[city]),VALUES('Table'[region]))
2. Then we can create a measure as below to get the excepted result as we need.
Measure = IF ( ISFILTERED ( 'Table'[city] ), SUM ( 'Table'[amount] ), IF ( ISFILTERED ( 'Table'[region] ), CALCULATE ( SUM ( 'Table'[amount] ), USERELATIONSHIP ( di[city / region], 'Table'[region] ) ) ) )
BTW, pbix as attached.
Hi @Anonymous
Unfortunately, there is no way to switch dynamically between columns or use measures in the Legend field of visuals, however, it would be a very powerful future.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
112 | |
99 | |
73 | |
72 | |
49 |
User | Count |
---|---|
145 | |
109 | |
109 | |
90 | |
64 |