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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
mdaamirkhan
Post Prodigy
Post Prodigy

What will be daxt for this logice  Last Invoice = max (Date) - today()

Hi All,

What will be daxt for this logice  Last Invoice = max (Date) - today()

 

1 ACCEPTED SOLUTION
StefanoGrimaldi
Resident Rockstar
Resident Rockstar

Last Invoice = 

LASTDATE(Date)
this will give you the higher date on a column, if you the days since the last invoice would be 

Last Invoice = 

LASTDATE(Date) - today()
 
if this helped give some kudos and mark as solution for others to find.




Did I answer your question? Mark my post as a solution! / Did it help? Give some Kudos!

Proud to be a Super User!




View solution in original post

8 REPLIES 8
StefanoGrimaldi
Resident Rockstar
Resident Rockstar

adjust to this formula them: 

Last Invoice = 

DATEDIFF( LASTDATE(Date), today(), MONTH)





Did I answer your question? Mark my post as a solution! / Did it help? Give some Kudos!

Proud to be a Super User!




mdaamirkhan
Post Prodigy
Post Prodigy

Any update

StefanoGrimaldi
Resident Rockstar
Resident Rockstar

Last Invoice = 

LASTDATE(Date)
this will give you the higher date on a column, if you the days since the last invoice would be 

Last Invoice = 

LASTDATE(Date) - today()
 
if this helped give some kudos and mark as solution for others to find.




Did I answer your question? Mark my post as a solution! / Did it help? Give some Kudos!

Proud to be a Super User!




will it give in months as I need in months

adjust to this formula them: 

Last Invoice = 

DATEDIFF( ASTDATE(Date), today(), MONTH)





Did I answer your question? Mark my post as a solution! / Did it help? Give some Kudos!

Proud to be a Super User!




amitchandak
Super User
Super User

@mdaamirkhan , Please try a measure 

 

datediff(maxx(allselected('Date'),'Date'[Date]), Today(), day)

not working it return 0 value

Hi,

Share some data and show the expected result.


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

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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