運用在同一個資料表中, 這一筆減去上一筆的時間差,
或兩筆資料間的資料處理
select a.v_order,
to_char(a.time_log,'YYYY/MM/DD HH24:MI') start_time,
b.v_order,
to_char(b.time_log,'YYYY/MM/DD HH24:MI') stop_time,
from ( select rownum v_order,
t1
from test1 ) a,
( select rownum v_order,
t2
from test1 ) b
where a.v_order=b.v_order-1
沒有留言:
張貼留言