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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

dax measure show the highest value in a period

Hi guys,

 

Im trying to show only the month's max value along the period, but it isn't work it.

 

I have try a lot of option... I confess... I'm frustate. Here is the last formula.

 

MAXX Distinctcount Unique Contract = maxx(allselected(d_NTT_Dinamic_DataTable[Month Name]),DISTINCTCOUNTNOBLANK('BaseContratosMensais_IndicadorGerencial - SQL Results'[#UNIQUE_CONTRACT]))
 
 

max question.png

Tks,

---

Alexandre.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

I have found a solution.

 

Top 1 Rank = CALCULATE([Distinctcount Unique Contracts],CALCULATETABLE(TOPN(1,ALL(d_NTT_Dinamic_DataTable[Month Name]),[Distinctcount Unique Contracts],DESC),ALL(d_NTT_Dinamic_DataTable),VALUES(d_NTT_Dinamic_DataTable[FY_NTT])))

 

After that, I have made a chart to highlight the major value.

 

Many thanks everybody.

 

truebeatles_0-1613590598488.png

 

View solution in original post

6 REPLIES 6
Anonymous
Not applicable

It changed a little bit, but it not what I'm looking for.

 
Top 1 Rank = CALCULATE([Distinctcount Unique Contracts],TOPN(1,ALL(d_NTT_Dinamic_DataTable[Month Name]),[Distinctcount Unique Contracts],DESC),VALUES(d_NTT_Dinamic_DataTable[Month Name]))
truebeatles_0-1612468243319.png

 

Tks,

---

Alexandre.

amitchandak
Super User
Super User

@Anonymous , Try TOPN on month

 

Top 1 Rank = CALCULATE([Distinctcount Unique Contract],TOPN(1,all(Table[Month Year]),[Distinctcount Unique Contract],DESC),VALUES(Table[Month Year]))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

It changed a little bit, but it not what I'm looking for.


Top 1 Rank = CALCULATE([Distinctcount Unique Contracts],TOPN(1,ALL(d_NTT_Dinamic_DataTable[Month Name]),[Distinctcount Unique Contracts],DESC),VALUES(d_NTT_Dinamic_DataTable[Month Name]))

 

I'm looking for this.

max question1.png

Tks,
Alexandre.

@Anonymous , remove the other measure from the table and check.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

Same.

truebeatles_0-1612535132351.png

 

Anonymous
Not applicable

I have found a solution.

 

Top 1 Rank = CALCULATE([Distinctcount Unique Contracts],CALCULATETABLE(TOPN(1,ALL(d_NTT_Dinamic_DataTable[Month Name]),[Distinctcount Unique Contracts],DESC),ALL(d_NTT_Dinamic_DataTable),VALUES(d_NTT_Dinamic_DataTable[FY_NTT])))

 

After that, I have made a chart to highlight the major value.

 

Many thanks everybody.

 

truebeatles_0-1613590598488.png

 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

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.