Forum Discussion
RishikeshD
3 years agoNew Member
How to compare time in DAX ?
I have written following DAX code to compare if vehicle has arrived on time ( set at 12 here) . I have an Inward Table wgich has Inward Time Column of Type Short Time . Vehicle Arrival Window Com...
- Anonymous3 years ago
Hi RishikeshD
You can try the following code:
Vehicle Arrival Window Comformity = COUNTX(inward,TIMEVALUE(inward[Inward Time])>TIMEVALUE("12:00"))Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ppm1
Solution Sage
3 years agoPlease see this article. When dealing with dates/times, it is a good practice to handle them as the numbers they are behind the scenes, and only format/display your result at the end.
Calculate and Format Durations in DAX – Hoosier BI
Pat