Forum Discussion
Anonymous
3 years agoNot applicable
Datediff Question
Hello, Taking this COD_UID as How can I perform a datediff in seconds between the dates with the status shipped and the dates with the status Packed for the same COD_UID?7 Sample here: S...
- 3 years ago
Hi Anonymous ,
Please try:
Measure = var _a = CALCULATE(MAX('Table'[Picking Time_]),FILTER('Table',[STATUS]="SHIPPED")) var _b = CALCULATE(MAX('Table'[Picking Time_]),FILTER('Table',[STATUS]="PACKED")) return DATEDIFF(_a,_b,SECOND)Output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
v-jianboli-msft
3 years agoCommunity Support
Hi Anonymous ,
Please try:
Measure =
var _a = CALCULATE(MAX('Table'[Picking Time_]),FILTER('Table',[STATUS]="SHIPPED"))
var _b = CALCULATE(MAX('Table'[Picking Time_]),FILTER('Table',[STATUS]="PACKED"))
return DATEDIFF(_a,_b,SECOND)
Output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.