- 博客(9)
- 资源 (12)
- 收藏
- 关注
原创 查询并自动创建Missing Index
SELECT migs.avg_total_user_cost*(migs.avg_user_impact/ 100.0)*(migs.user_seeks+ migs.user_scans)ASimprovement_measure, 'CREATE INDEX[missing_index_' + CONVERT(varchar, mig.index
2012-12-27 10:31:24 1568
原创 使用ApexSQL Log 分析数据库在线日志及数据库备份
今天遇到一个问题,数据库有几张表的数据被清除了。因为数据是昨天晚上被删除的,当时没有用户访问,所以根据日志备份就可以将数据还原,没有数据损失。但是是谁删除了数据呢? 在2008之前有很多工具都可以分析数据库的在线日志和备份文件,但是支持2008以及更高版本的不是很多。这里我是用了ApexSQL Log 2011,关于ApexSQL Log 2011的功能: ApexSQL Log
2012-12-25 17:22:57 15177 11
原创 已备份数据库的磁盘结构版本为611,服务器支持版本为539,无法还原或升级数据库
大家都知道高级版本的数据库文件无法还原或者附加到低版本,因为高版本和低版本文件格式会有不同。如果尝试将低版本的数据库附加或者还原到低版本的数据库会看到类似下面的错误: 已备份数据库的磁盘结构版本为611,服务器支持版本为539,无法还原或升级数据库。RESTORE FILELIST 操作异常结束。(MicrosoftSQL Server,错误:3169) 可以看到这里有两个版本
2012-12-21 13:17:19 50657
原创 Worktable大量逻辑读
今天早论坛看到一篇帖子说程序运行的比较慢,看到IO统计信息中有一条是扫描了'Worktable'。从网上又看到了相同的帖子: Table 'Worktable'.Scan count 0, logical reads7523,physical reads 0Table 'Employee'. Scan count 1, logical reads106, physical read
2012-12-20 17:21:53 6171
原创 缓慢变化维----slowly changing dimension 处理 办法
维度建模的数据仓库中,有一个概念叫Slowly Changing Dimensions,中文一般翻译成“缓慢变化维”,经常被简写为SCD。缓慢变化维的提出是因为在现实世界中,维度的属性并不是静态的,它会随着时间的流失发生缓慢的变化。这种随时间发生变化的维度我们一般称之为缓慢变化维,并且把处理维度表的历史变化信息的问题称为处理缓慢变化维的问题,有时也简称为处理SCD的问题。处理缓
2012-12-18 21:17:01 2235
原创 Error: 1934 INSERT failed because the following SET options have incorrect settings: 'ARITHABORT'.
今天对一个Index做了调整,为了提高性能将Index修改为FilteredIndex,结果一个JAVA程序出现了下面的错误: Error: 1934, Severity: 16, State: 1 INSERT failed because thefollowing SET options have incorrect settings: 'ARITHABORT'. Verif
2012-12-18 14:18:51 3443
原创 查询Index使用状况SQL
SELECT sch.name +'.' + t.nameAS [Table Name], i.name AS[Index Name], i.type_desc, ISNULL(user_updates,0)AS [Total Writes], ISNULL(user_seeks+user_sc
2012-12-18 11:49:34 1099
转载 一个查询窗口并行运行SQL脚本
在论坛看到有朋友想在一个窗口并行跑多条语句,但是没有好的办法。 我从网上找到了下面的办法,创建一个数据库的Project然后运行就可以实现并行运行数据库脚本的功能,希望对大家有帮助。 Transact-SQL does not have a simple method to launch multiple parallel running scripts. The pmaster is a
2012-12-14 16:28:23 1519
原创 SQL Server做完整备份步骤
四个步骤: 1. Checkpoint database means that SQL Server writes all dirty pages (pages that have changed since loaded into memory) to disk to ensure only committed transactions included in full
2012-12-14 15:49:36 1357
The Guru's Guide to SQL Server Architecture and Internals.chm
2009-10-13
Sqlserver性能调整
2009-09-27
使用CPU计数器监视SQL Server性能的
2009-09-27
inside-microsoft-r-sql-server-tm-2005-the-storage-engine
2009-09-27
SQL SERVER 2005
2009-09-27
SQL+Server+2005技术内幕-存储引擎1-5章.pdf
2009-09-24
Microsoft Press - Inside Microsoft SQL Server 2005 Query Tuning and Optimization (Sep 2007).chm
2009-09-24
Inside Microsoft SQL Server 2005: T-SQL Programming
2009-09-24
SQL.Server.2005.Administration
2009-05-25
TSQL Query Tuning
2009-05-25
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人