用最简单的方法记录Oracle语句的执行时间
在实际的工作和学习中,许多人经常需要获取或记录Oracle语句的执行时间 ,其实简单的方法就能实现,具体代码如下:
OracleE语句的执行时间需要使用 SET TIMING ON,例如:
[oracle@jw ~]$ sqlplus "/as sysdba" SQL*Plus: Release 9.2.0.4.0 - Production on 星期二 8月 28 16:59:43 2007 Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved. |
连接到:
Oracle9i EntERPrise Edition Release 9.2.0.4.0 - Production With the Partitioning, Oracle Label Security, OLAP and Oracle Data Mining options JServer Release 9.2.0.4.0 - Production SQL> set timing on; SQL> select count(*) from tab; COUNT(*) ---------- 2447 已用时间: 00: 00: 00.12 SQL> |
版权声明:本文由驱动中国整理发布,转载需注明出处与原文链接。如有疑问请联系
editor@qudong.com。
本文价值
★★★★★
—
成为第一个评分的人
登录后为本文打分
评论加载中…