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

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

Reply
Yanou
Helper II
Helper II

How to spot Last date and enter it in column

Hello,

 

Please someone help me in my issue. I have accounts in a column and for each account there is a operation date (in an other column). 

 

I would like, in a calculated column, for each line, that PBI manage to spot the latest date. Then PBI enter the data date in all the Lines of the column who have the same account.

 

Informations : in the column accounts, the same account can be several times repeat. 

 

Thanks a lot.

 

Yannick

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

@Yanou Try:

Column = 
  VAR __Account = [Account]
  VAR __Table = FILTER('Table',[Account] = __Account)
  VAR __MaxDate = MAXX(__Table,[Date])
RETURN
  __MaxDate


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

4 REPLIES 4
Greg_Deckler
Community Champion
Community Champion

@Yanou Try:

Column = 
  VAR __Account = [Account]
  VAR __Table = FILTER('Table',[Account] = __Account)
  VAR __MaxDate = MAXX(__Table,[Date])
RETURN
  __MaxDate


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Hello Greg,

 

I read your article on "Dealing with Measure Totals". I understand that the measure doesn't make the total in adding the detail lines. You note that one should use Hasnofilter to have the correct total :

 

Can you please tell me how to add a Hasnofilter function in the folowing measure to have the right total line  ?

 

Montant financé2 = SUMX (SUMMARIZE ('SAP compta','SAP compta'[Element OTP],'Taux par financeurs'[Financement]
),
'Taux par financeurs'[Financement]*[Dépenses éligibles FAP/FHP V2 (apres T1/Date fin)]
)
 
 
Thanks you

 

Thank you for your help !

Hello Greg,

 

Thanks for the help, I try that this morning. A question, in your formula "VAR __Account = [Account]",  "[Account]" is a measure to create?

 

Thanks

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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.

Top Kudoed Authors