dateDiff not returning hours when setting date part to 'HH'

0

While trying to find the difference in hours between two timestamps, i am receiving zero's for all results.

  • first calculation attempted & results: datediff({ride_winning_eta_submitted_time},{ride_status_to_pickup_at}) |Date 1| Date 2 | time diff in hours| | Aug 21, 2022 11pm | Aug 21, 2022 12 am | 0 | | Aug 21, 2022 1pm | Aug 21, 2022 4pm | 0 |

I would expect to see the below | Aug 21, 2022 11pm | Aug 21, 2022 12 am | 1 | | Aug 21, 2022 1pm | Aug 21, 2022 4pm | 3 |

I have also tried to simply extract the hour and then subtract those values but this will not take into account multiple days between, this only works if it is all same day interactions. The last thing i tried to do that is slightly different from the above is datediff({ride_winning_eta_submitted_time},{ride_status_to_pickup_at},"HH"), then focusing on hour within the columns and this gave me the same results as above.

Thanks in advance for any help here!

已提問 2 年前檢視次數 461 次
1 個回答
0
已接受的答案

I ended up figuring out what the issue was. I have to very similarly named fields and selected the non timestamp one accidentally and did not realize it.

已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南