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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Easley08
Helper I
Helper I

Getting the Last purchase date in Cards

Hi,

 

is there a way to only show only the latest purchase based on this table i alread created the measures 

but i want to show only the latest in the Card

 

Easley08_1-1741865677970.png

 

 

measures : 

Last Purchase Date = LASTDATE(Sales[Purchase Date])
 
for tagging i try this measure 
Last Purchase Tag Year = IF([LP Year] > [FP Year] && [Last Purchase Date] > VALUES(Customer[first_purchase_date]) ,1,0)
 
 
thanks.
1 ACCEPTED SOLUTION
bhanu_gautam
Super User
Super User

@Easley08 Create a measure to get the latest purchase date:

Latest Purchase Date = MAX(Sales[Purchase Date])

 

Create a measure to get the outlet name of the latest purchase:

Latest Outlet Name =
CALCULATE(
FIRSTNONBLANK(Sales[Outlet Name], 1),
Sales[Purchase Date] = [Latest Purchase Date]
)

 

Create a measure to get the purchase date of the latest purchase:

Latest Purchase Date Display =
CALCULATE(
MAX(Sales[Purchase Date]),
Sales[Purchase Date] = [Latest Purchase Date]
)

 

Create a measure to get the LP Year of the latest purchase:

Latest LP Year =
CALCULATE(
MAX(Sales[LP Year]),
Sales[Purchase Date] = [Latest Purchase Date]
)




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






View solution in original post

2 REPLIES 2
bhanu_gautam
Super User
Super User

@Easley08 Create a measure to get the latest purchase date:

Latest Purchase Date = MAX(Sales[Purchase Date])

 

Create a measure to get the outlet name of the latest purchase:

Latest Outlet Name =
CALCULATE(
FIRSTNONBLANK(Sales[Outlet Name], 1),
Sales[Purchase Date] = [Latest Purchase Date]
)

 

Create a measure to get the purchase date of the latest purchase:

Latest Purchase Date Display =
CALCULATE(
MAX(Sales[Purchase Date]),
Sales[Purchase Date] = [Latest Purchase Date]
)

 

Create a measure to get the LP Year of the latest purchase:

Latest LP Year =
CALCULATE(
MAX(Sales[LP Year]),
Sales[Purchase Date] = [Latest Purchase Date]
)




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






Hi sir im getting error for this 

Easley08_0-1741867556097.png

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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