Forum Discussion
Calculated Column for Latest Training Date
- 5 years ago
Gaurav_Lakhotia , From what I got.
You can have new column which tell diff from last training and you can use that
new column =
Datediff( maxx(filter(table ,[Customers Name] = earlier([Customers Name]) && [TrainingDate] <earlier([TrainingDate])),[TrainingDate]),[TrainingDate],day) - 5 years ago
Hi amitchandak ,
The DAX you've shared is calculating by taking very first Customer Training date as a base.
We want it to consider every corresponding training date of each row to search within 28 days after training.
Thanks
Gaurav_Lakhotia I will look at PBIX but could you just use:
New Column = [Training Date] + 28
New Column 1 = IF([Second Training Date] < [New Column],[Second Training Date]+28,<something else>)
- Gaurav_Lakhotia5 years agoHelper III
Hi Greg_Deckler ,
We've Customer Name column. We've to lookup training dates customer wise. Here is sample data, look for first 2 entries of Sweet House Day Spa. We've 6 May 2020 and 16 May 2020.
TrainingDate Trainer'sName Trainer'sType Customer's Name
02-09-2020 Jessica Building a Strong Front Desk Team Sweet House Day Spa - Houston 04-09-2020 Brittany Building a Strong Front Desk Team 101 Skin Lab 06-09-2020 Brittany Inventory Control / Product Management A New Leaf Flowers, Gifts, & More 06-05-2020 Brittany Advanced Modality Treatments Sweet House Day Spa 18-06-2020 Jennifer Advanced Modality Treatments Aidan James Salon 26-06-2020 Wendy Advanced Modality Treatments 101 Market 16-06-2020 Jessica Building a Strong Front Desk Team Sweet House Day Spa 07-09-2020 Becky Building a Strong Front Desk Team 502 Flair 23-05-2020 Brittany Advanced Modality Treatments Sweet House Day Spa - amitchandak5 years agoSuper User
Gaurav_Lakhotia , From what I got.
You can have new column which tell diff from last training and you can use that
new column =
Datediff( maxx(filter(table ,[Customers Name] = earlier([Customers Name]) && [TrainingDate] <earlier([TrainingDate])),[TrainingDate]),[TrainingDate],day)- Gaurav_Lakhotia5 years agoHelper III
Hi amitchandak ,
The DAX you've shared is calculating by taking very first Customer Training date as a base.
We want it to consider every corresponding training date of each row to search within 28 days after training.
Thanks