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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Syndicate_Admin
Administrator
Administrator

Column with the maximum value

Hello good afternoon community, for your help with the following query:

I have the following table grouped together:

Chentefx_0-1726529501296.png

The Maximum Value of the quantity field is searched (In this case it is 16)

When performing the measured field

Max = MAX('DayWithMaxTransactions'[TransactionCount])
Max = MAXA('DayWithMaxTransactions'[TransactionCount])
Max = MAXX('DayWithMaxTransactions'[TransactionCount])

The result is:
Chentefx_1-1726529635616.png

I have tried with the functions it indicates and it keeps giving me the number 3 instead of 16 which would be the correct data.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Chentefx ,

 

Maybe there're some filters that cauesd the wrong result of your measure.

You can try this measure:

HTX_Maximo =
MAXX (
    SUMMARIZE (
        ALL ( 'DayWithMaxTransactions' );
        'DayWithMaxTransactions'[HProcess].[Año];
        'DayWithMaxTransactions'[HProcess].[Mes];
        'DayWithMaxTransactions'[HProcess].[Día];
        DayWithMaxTransactions[TransactionCount]
    );
    'DayWithMaxTransactions'[TransactionCount]
)

The ALL function can ignore any filters applied.

 

Best Regards,

Stephen Tao

 

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

 

View solution in original post

7 REPLIES 7
Anonymous
Not applicable

Hi @Chentefx ,

 

Maybe there're some filters that cauesd the wrong result of your measure.

You can try this measure:

HTX_Maximo =
MAXX (
    SUMMARIZE (
        ALL ( 'DayWithMaxTransactions' );
        'DayWithMaxTransactions'[HProcess].[Año];
        'DayWithMaxTransactions'[HProcess].[Mes];
        'DayWithMaxTransactions'[HProcess].[Día];
        DayWithMaxTransactions[TransactionCount]
    );
    'DayWithMaxTransactions'[TransactionCount]
)

The ALL function can ignore any filters applied.

 

Best Regards,

Stephen Tao

 

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

 

Ashish_Mathur
Super User
Super User

Hi,

This pattern should work

Measure = MAXX(SUMMARIZE(Calendar,Calendar[year],calendar[month name],"A",[Total]),[A])

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hello good, I have followed the suggestion only that now it gives me the result of 1.
Here's the filter from the initial table:

DayWithMaxTransactions =
VAR FilteredTable =
FILTER(
'HistoryTransaction';
WEEKDAY('HistoryTransaction'[HProcess]) = WEEKDAY(TODAY())
&& 'HistoryTransaction'[Origen] <> 'HistoryTransaction'[Destino]
&& 'HistoryTransaction'[Destino] = "1"
&& 'HistoryTransaction'[HStatus] = 4
)
VAR GroupedTable =
SUMMARIZECOLUMNS (
'HistoryTransaction'[HProcess];
FilteredTable;
"TransactionCount"; COUNT('HistoryTransaction'[idHistoricoTx])
)

RETURN GroupedTable

Thus the data is grouped and filtered

Chentefx_0-1726589049708.png

Siguiendo la sugerencia del maximo
HTX_Maximo =
MAXX(
SUMMARIZE(
'DayWithMaxTransactions';
'DayWithMaxTransactions'[HProcess]. [Año];
'DayWithMaxTransactions'[HProcess]. [Mes];
'DayWithMaxTransactions'[HProcess]. [Día];
DayWithMaxTransactions[TransactionCount]
);
'DayWithMaxTransactions'[TransactionCount])

I have done it in the two ways that have been recommended to me, now I get the result of

Chentefx_0-1726588814344.png

The measure you have written is nowhere close to the one which i suggested.  I am referring to the Calendar table - you are not.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Good day my dear, apologies since I am entering the world of power bi and it is costing me a little, I do not know if it is necessary to create the calendar table, in my case I make the direct consultation, in advance I appreciate you can explain me, since I have lost myself in the solution of the problem.

It is necessary to create a Calenda table.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
lbendlin
Super User
Super User

You have daily data, so it returns the maximum transactions you had on a single day.

 

Use an aggregation function like SUMMARIZECOLUMNS over the years and months, and then take the MAXX over that aggregator.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.