Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Good afternoon,
I have the following DAX formula which I have been using to find the date a vehicle was last inspected:
Solved! Go to Solution.
Hi Msommerf,
While I dont have any advice with regards to M. You could try the following table based caluclation. Please note that this assumes that the fields available are within the same table. If not It may be worth bringing the fields from other tables into this one through their shared ID relationship:
Calculate(Max([InspectionCompleted]),Filter(All([INSPECTIONCOMPLETEDTABLE]),
ASSETID = Earlier(ASSETID) &&
InspectionCompleted<Date_Occured ))
The calculation may run more efficiently if its does not have to look to other tables.
Hi @msommerf,
AFAIK, current power query functions are also not suitable for your requirement. They are good at data shaping/clean and transform data structure instead of calculation through whole table records with particular filters.
BTW, what type of data source are you worked on? If you are using SQL server or other data source that supported advanced queries, you can try to use query to add some additional fields to reduce the looping calculations.
Regards,
Xiaoxin Sheng
Hi Msommerf,
While I dont have any advice with regards to M. You could try the following table based caluclation. Please note that this assumes that the fields available are within the same table. If not It may be worth bringing the fields from other tables into this one through their shared ID relationship:
Calculate(Max([InspectionCompleted]),Filter(All([INSPECTIONCOMPLETEDTABLE]),
ASSETID = Earlier(ASSETID) &&
InspectionCompleted<Date_Occured ))
The calculation may run more efficiently if its does not have to look to other tables.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
99 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
87 | |
64 |