摘要: 作为一名DBA,他们最常见的日常任务是:1)定期完成数据库的完全备份或差异备份。2)定期清理备份文件,因为存储空间有限,可能只需要保存一个时期段内的文件(比如一周内或一月内)。而如何做到这两点呢?笔者相信在SQL SERVER2005版本出来之前要实现这种功能, 也是可以实现的,只是实现定期清理备份文件显得不那么直接,一般需要手写批处理作业维护,而在SQL Server 2005版本中,这些功能已... 阅读全文
posted @ 2009-10-21 18:00 programming snail 阅读(397) 评论(1) 推荐(0) 编辑
摘要: It's a familiar problem for most developers. The application is just about finished, the near-final bits are rolled out to the test servers...and things aren't quite fast enough to suit everyone. As y... 阅读全文
posted @ 2009-10-20 14:47 programming snail 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 近期因工作需要,希望比较全面的总结下SQL SERVER数据库性能优化相关的注意事项,在网上搜索了一下,发现很多文章,有的都列出了上百条,但是仔细看发现,有很多似是而非或者过时(可能对SQL SERVER6.5以前的版本或者ORACLE是适用的)的信息,只好自己根据以前的经验和测试结果进行总结了。我始终认为,一个系统的性能的提高,不单单是试运行或者维护阶段的性能调优的任务,也不单单是开发阶段的事情... 阅读全文
posted @ 2009-10-20 11:00 programming snail 阅读(302) 评论(0) 推荐(1) 编辑
摘要: Sql Server Database IndexesMost ASP.NET web application connect to a database, and you want to make sure the queries and stored procedures used to query the database run as optimal as possible. If you... 阅读全文
posted @ 2009-10-19 15:27 programming snail 阅读(328) 评论(0) 推荐(0) 编辑
摘要: 对于今天的 RDBMS 体系结构而言,死锁难以避免 — 在高容量的 OLTP 环境中更是极为普遍。正是由于 .NET 的公共语言运行库 (CLR) 的出现, SQL Server 2005 才得以为开发人员提供一种新的错误处理方法。在本月专栏中, Ron Talmage 为您介绍如何使用 TRY/CATCH 语句来解决一个死锁问题。 一个示例死锁让我们从这样一个示例开始说起,它在 SQ... 阅读全文
posted @ 2009-10-12 10:32 programming snail 阅读(572) 评论(0) 推荐(1) 编辑
摘要: 1. Use stored procedures instead of heavy-duty queries. This can reduce network traffic as your client will send to the server only the stored procedure name (perhaps with some parameters) instead of ... 阅读全文
posted @ 2009-10-08 11:18 programming snail 阅读(393) 评论(0) 推荐(0) 编辑
摘要: select语句中只能使用sql函数对字段进行操作(链接sql server),select 字段1 from 表1 where 字段1.IndexOf("云")=1;这条语句不对的原因是indexof()函数不是sql函数,改成sql对应的函数就可以了。left()是sql函数。select 字段1 from 表1 where charindex('云',字段1)=1;字符串函数对二进制数据、字... 阅读全文
posted @ 2009-10-08 11:13 programming snail 阅读(322) 评论(1) 推荐(0) 编辑