易截截图软件、单文件、免安装、纯绿色、仅160KB

使用set statistics on 来检查sql tuning的结果


在SQL Server2005/2008中可以使用一下四个命令来调优sql语句以及检查调优的结果
set
 statistics time on

set
 statistics IO on

set
 statistics profile on

set
 statistics xml on



相关文档:

sql日期模糊查询 SQL时间转换格式

Select * from t_user_profile where convert ( varchar ( 21 ),regDate, 120 ) like ' 2008-05-07% ' 表名称:t_user_profile 日期字段名称:regDate
Select   *   from t_user_profile  where  convert(varchar(21),regDate,120) like '2008-05-07%'< ......

PL/SQL学习笔记三


1.条件控制
1.1 if .. then .. end if
if 条件 then
    语句段;
end if;
1.2 if .. then .. else .. end if
if 条件 then
    语句段;
else 
    语句段;
end if;
1.3 if嵌套
2.循环控制
2.1 loop .. exit .. end loop
loop  
   & ......

SQL*Plus FAQ

 What is SQL*Plus and where does it come from?
SQL*Plus is a command line SQL and PL/SQL language interface and reporting tool that ships with the Oracle Database Client and Server software. It can be used interactively or driven from scripts. SQL*Plus is frequently used by DBAs and Developers ......

Oracle维护常用SQL语句汇总

Oracle维护常用SQL语句汇总
上一篇 / 下一篇  2008-09-04 11:25:01
查看( 1991 ) / 评论( 0 ) / 评分( 0 / 0 )
如何远程判断Oracle数据库的安装平台
select * from v$version;
查看表空间的使用情况
select sum(bytes)/(1024*1024) as free_space,tablespace_name
from dba_free_space
group by tablespace_ ......

SQL优化34条


(1)      选择最有效率的表名顺序(只在基于规则的优化器中有效):
ORACLE 的解析器按照从右到左的顺序处理from子句中的表名,from子句中写在最后的表(基础表 driving table)将被最先处理,在from子句中包含多个表的情况下,你必须选择记录条数最少的表作为基础表。如果有3个以上的表连接查询, 那就需要 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号