Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi there,
I have three table,
Group,Product,Sales
And I want to creat a new measure to show the max value for sales by groupname.
How to do this ? Please help me.
BRs
Dora.
Solved! Go to Solution.
Hi,
thank you for your explanation, and please check the below picture and the attached pbix file.
The new measure has to be written like below, and then you can select this measure as a "Field Value" inside the Conditional Formatting -> Background color option.
Max sales value by groupname color format: =
VAR maxsales =
CALCULATE ( MAX ( Sales[Sales] ), ALLEXCEPT ( Sales, 'Group'[GroupName] ) )
RETURN
IF ( SUM ( Sales[Sales] ) = maxsales, "Red" )
@Anonymous Find the attached PBIX file for your reference. Refer the Relationship tab for joining between tables. then simply take sales and GroupName into simple table or visual.
Hi,
I am not sure if I understood your question correctly, but please check the below picture and the attached pbix file.
It is for creating a new measure.
Max sales value by groupname: =
SUMX ( VALUES ( 'Group'[GroupName] ), CALCULATE ( MAX ( Sales[Sales] ) ) )
Hi @Jihwan_Kim ,
Sorry I told not so clear,
My final purpose is to do like this.
The max turn background color in the same groupname.
How to do this? Thanks a lot.
BRs
Dora.
Hi,
thank you for your explanation, and please check the below picture and the attached pbix file.
The new measure has to be written like below, and then you can select this measure as a "Field Value" inside the Conditional Formatting -> Background color option.
Max sales value by groupname color format: =
VAR maxsales =
CALCULATE ( MAX ( Sales[Sales] ), ALLEXCEPT ( Sales, 'Group'[GroupName] ) )
RETURN
IF ( SUM ( Sales[Sales] ) = maxsales, "Red" )
@Anonymous , Join sales with product table
then you can show
max(Sales[sales])
or
maxx(values(Product[Group Name]) , calculate(sum(sales[sales])))
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
58 | |
56 | |
56 | |
38 | |
29 |
User | Count |
---|---|
75 | |
62 | |
45 | |
40 | |
39 |