cancel
Showing results for
Did you mean:
Frequent Visitor

## Display the month name of month which had maximum (monthly) sales

I have managed to show the sales figure of the month which had highest sales.

However I want to display the month name which had the highest monthly sales in the selected year.

1 ACCEPTED SOLUTION
Community Support

Hi @km_km2023 ,

Like this?

First , create a measure:

``max = IF(SELECTEDVALUE('Table'[value])=MAXX(ALL('Table'),'Table'[value]),1,0)``

Then, put this measure into visual filter:

You can get the above result.

Best regards,

Community Support Team Selina zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

4 REPLIES 4
Community Support

Hi @km_km2023 ,

Like this?

First , create a measure:

``max = IF(SELECTEDVALUE('Table'[value])=MAXX(ALL('Table'),'Table'[value]),1,0)``

Then, put this measure into visual filter:

You can get the above result.

Best regards,

Community Support Team Selina zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Resolver II

Hello,

You can try this - MAX_VAL = Calculate(MAX(Table[value],ALLEXCEPT(Table,Table[category]))

Frequent Visitor

I dont think this works actually. I want to display the month name and not the monthly sales.

I would want the outcome to be "Mar" in the below scenario. Also the data is by each line, hence the below table I have shown only for example purposes.

Resolver II
MAX_VAL = CONCATENATE(LOOKUPVALUE(Sales[Product],Sales[Profit],MAX(Sales[Profit])),MAX(Sales[Profit]))
This has worked in my case - Concatinated Max vaue and Product.
i have calulated max first then added lookup for Product basis to Max value, and then concatnated both the things.