如何在 oracle 11g 中查找 sql table 的所有记录的每小时时差?

how to find hourly time difference all record from sql table in oracle 11g?

我想 select table 命名拼车的所有条目,其中 ends_on 和 start_on 之间的时差是 1 小时 有人可以帮我写查询吗解释?我在下面的链接中附上了图片。

table reference

click here for query reference

试试这个,将时间戳转换为日期并按天减去

  select *
  from carpooling
  where trunc(cast(ends_on as date),'mi')-trunc(cast(start_on as date),'mi')=1/24