1.在sql提示符显示当前时间
set time on,缺省是off
2.显示sql执行消耗的时间
set timing on,缺省是off
3.使用
SQL> show time
time OFF
SQL> show timing
timing OFF
SQL> select * from t2 where rownum < 2;
ID NAME
---------- --------------------
0 abc
SQL> set time on
21:46:46 SQL> select * from t2 where rownum < 2;
ID NAME
---------- --------------------
0 abc
21:46:53 SQL> set timing on
21:46:58 SQL> select * from t2 where rownum < 2;
ID NAME
---------- --------------------
0 abc
已用时间: 00: 00: 00.00
21:47:05 SQL>
--------