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

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
powerbiexpert22
Post Prodigy
Post Prodigy

max sales based on only category

1 ACCEPTED SOLUTION
v-cgao-msft
Community Support
Community Support

Hi @powerbiexpert22 ,

Please try this measure:

Max Sales = 
    MAXX( 
        FILTER(
            SUMMARIZE(
                ALLSELECTED('Orders'),
                'Orders'[Category],
                'Calendar'[Month]
            ),
            'Orders'[Category]=SELECTEDVALUE('Orders'[Category])
        ),
        [TSales]
    )

vcgaomsft_0-1715147966564.png

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum -- China Power BI User Group

View solution in original post

2 REPLIES 2
v-cgao-msft
Community Support
Community Support

Hi @powerbiexpert22 ,

Please try this measure:

Max Sales = 
    MAXX( 
        FILTER(
            SUMMARIZE(
                ALLSELECTED('Orders'),
                'Orders'[Category],
                'Calendar'[Month]
            ),
            'Orders'[Category]=SELECTEDVALUE('Orders'[Category])
        ),
        [TSales]
    )

vcgaomsft_0-1715147966564.png

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum -- China Power BI User Group

fahadqadir3
Super User
Super User

@powerbiexpert22 

Please review the attached screenshot, and use the following measure to sum based on Business Unit.

Measure Fixed = CALCULATE(

    SUM('Table'[value]),

    ALLEXCEPT('Table','Table'[BU])

Fixed LOD.jpgjgeddes_0-1715088371426.png

 

BU Actual Total = 
CALCULATE(
    SUM('Table'[Actual]),
    ALLEXCEPT('Table', 'Table'[Business Unit])
)

 

Similarly, in your case you can use the following measure

MAX SALES= CALCULATE( SUM('Table'[TSales]),
ALLEXCEPT('Table', 'Table'[Category) )

 

Helpful resources

Announcements
March PBI video - carousel

Power BI Monthly Update - March 2025

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

March2025 Carousel

Fabric Community Update - March 2025

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

Top Solution Authors