自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Kevin's Blog SQL讨论群21426959 Dynamics AX 438084988

技术是靠累计的,每天记录一点。 关注数据库,BI,大树据,移动开发,云技术

  • 博客(12)
  • 资源 (12)
  • 收藏
  • 关注

原创 如何查看当前Open的Cursor

遇到错误:A cursor with thename ' ' already exists,想要看是什么代码导致的。找到下面几种方法. --测试声明Cursor并且打开DECLARE vend_cursor CURSOR GLOBAL    FOR SELECT * FROMPurchasing.VendorOPEN GLOBALvend_cursor

2013-12-30 21:20:40 1417

原创 Set statistics time 输出 CPU time> elapsed time

今天用Set Statisticis time比较语句的执行时间,信息如下: SQL ServerExecution Times:   CPU time = 199229 ms,  elapsed time =156327 ms.SQL Serverparse and compile time:    CPU time = 0 ms, elapsed time = 0

2013-12-26 17:06:58 1460

原创 分析SQL Server 给出的missing index建议

测试基于SQL Server 2008  AdventureWorks2008,TablePerson.Person.表中已经存在的索引定义: CREATE NONCLUSTEREDINDEX [IX_Person_LastName_FirstName_MiddleName] ON [Person].[Person] (    [LastName] ASC,    [F

2013-12-25 20:35:30 2977

原创 Reporting Service textbox换行

如果字符串很长,希望在SSRS中的textbox中按照要求换行,该如何实现呢? 可以直接使用换行符vbCrLf 比如在TextBox的表达式中输入: ="Test Name" + vbCrLf +vbCrLf +"Number” + vbCrLf +vbCrLf +”Priority” 就可以出现下面的效果: 可以看到既有换行,而且每行中间还隔了一个空行。

2013-12-24 21:18:43 7059 1

原创 修改SQL Server Cluster 节点 IP地址

如何修改SQL Server集群虚拟地址的文章,微软已经有专门的KB介绍,这里测试修改集群节点的IP地址。以A/P集群举例: 1.      在Passive的Node上网络适配器修改IP地址。修改完成后会看到Cluster Event里面有无法连接到Node的错误。 2.      在集群管理器中刷新Network资源,发现Passive Node上修改的IP地址已经成功显示

2013-12-24 17:20:17 2907

原创 查询SQLServer的启动时间

上午在分析索引的使用情况,想看一下数据库什么时候启动的,确保统计的数据没有问题,可以使用下面三种方法查询: SELECT sqlserver_start_timeFROM sys.dm_os_sys_info select crdate from master..sysdatabaseswherename='tempdb' SELECT login_time F

2013-12-24 14:19:55 2115

原创 使用DBCC DBINFO查询数据库信息

在使用 DBCC DBINFO之前我们先看你下面几个问题: 1.  SQL Server是否升级过?安装时的版本是多少?2.  SQL Server当前的内部版本号是多少?3.  SQL Server上次成功运行DBCC CHECKDB的时间是多少?4.  日志是否被重建过5.  。。。。。。 上面所需要的信息只需要一个命令就可以了DBCC DBINFO(这个是Un

2013-12-20 09:58:18 2039

原创 Cognos中根据数据增长显示红绿灯

用户有一个需求,需要对比前后列的数值,如果负增长用红灯表示,正增长用绿灯,如果没有增长用黄灯表示。计算前后列数据的不同值可以使用Cognos的running-difference。 方法1:  打开GoSales(Query)的Package,使用库存名称空间的”国家或地区”,“期初盘存”两个字段,先创建列表拖入这两个字段。 在查询中创建两个新的数据项,分别命名为”Ru

2013-12-13 16:39:52 1581

原创 查询SQL Server Index上次Rebuild时间

朋友有一个Rebuild Index的Job执行一般停掉了,问我是否可以查看哪些Index已经被Rebuild过了。本来以为Sys.index或者Sys.objects会存储类似的信息,结果没有找到。 从网上查了一下,SQL Server没有存储类似的信息。但是因为Rebuild Index会自动更新统计信息,而统计信息的更新时间是可以获得的。所以我们可以大致根据统计信息的时间来估计。

2013-12-13 15:23:19 1651

转载 Cognos 如何让汇总行在明细列的顶部

用户希望将汇总的数据显示在第一行,但是Cognos默认出来的汇总数据是放在最后一行。在Cognos论坛看到一个帖子提到了解决办法: http://www.cognoschina.net/club/viewthread.php?tid=41673&pid=353555&page=1&extra=#pid353555 我按照上面文字提到的步骤自己做了一遍: 1.打开Report S

2013-12-06 11:27:50 2789

原创 SSIS 执行变量中的脚步输出列顺序与SQL查询列顺序不同

这个问题是朋友遇到的,做一个SSIS的程序将数据导入到txt。然后再用Oracle的工具导入到Oracle。但是在SSIS中执行变量脚步的时候,发现输出的列名称跟查询的列名称完全不同。 如图:   因为txt的格式已经定义好了,而且解析的程序也已经做好,所以如果txt列顺序有问题就会影响到后面的操作。查了一下好像没有地方可以调整输出量的顺序。 当然这个问题可以通过调

2013-12-04 10:53:21 1964

原创 2014 OLTP Memory Database lock 测试

根据微软的说法,由于内存数据库使用了乐观并发控制 ,所以事务不需要锁来锁定资源保证一致性。微软认为在内存数据库的事务中冲突和失败是非常少的情况,所以假定所有的并行事务都是成功的。因此写不会阻塞读,写也不阻塞写。 下面是原文:Transactionsin Memory-Optimized TablesInstead, transactions proceedunder the (op

2013-12-03 10:25:03 1270

The Guru's Guide to SQL Server Architecture and Internals.chm

I can pretty much guarantee that anyone who uses SQL Server on a regular basis (even those located in Redmond working on SQL Server) can learn something new from reading this book."

2009-10-13

Windows Server 2003 用户管理指南

由微软资深顾问,微软MVP所著,很精彩的一本书,希望对大家都有帮助

2009-09-27

Sqlserver性能调整

很多客户偶尔会遇到SQL Server 数据库性能下降。原因可能涉及从不良好的数据库设计到不正确的负载配置。作为一个管理员,你应该预先阻止或最小化问题,并当问题发生时,诊断原因并尽可能的做出正确的操作来解决问题。这片白皮书所述的问题通常来源于Microsoft® Corporation 的Customer Support Service(CSS or PSS)部门所遇到的,因为将所有可能的问题都详尽的分析是不合实际的。我们提供了按部就班的指导,通过使用可用的工具例如SQL Server Profiler,System Monitor和在SQL Server 2005中新的Dynamic Management View来为一般的性能问题诊断和排错。

2009-09-27

使用CPU计数器监视SQL Server性能的

当使用CPU计数器测量CPU活动时,记住下面是SQL Server中耗用CPU资源最多的进程: • 上下文切换:当SQL Server在多个CPU之间切换线程时就会发生上下文切换,过多的上下文切换会吃掉CPU资源。有些情况下,打开LightweightPooling选项可以减少上下文切换。

2009-09-27

inside-microsoft-r-sql-server-tm-2005-the-storage-engine

Although one goal of ours was to minimize the amount of overlap between volumes so that readers of the complete series would not have to deal with duplicate content, we also realized that not everyone would start with the same volume. Itzik and I have different approaches to describing SQL Server query processing, index use, and tuning, so when those topics are covered in more than one volume, that duplication is actually a bonus.

2009-09-27

SQL SERVER 2005

Written by a T-SQL guru, this thorough, hands-on reference for database developers and administrators focuses on language features and how they are interpreted and processed by the SQL Server execution engine.

2009-09-27

SQL+Server+2005技术内幕-存储引擎1-5章.pdf

Dive deep into the internals of query tuning and optimization in SQL Server 2005 with this comprehensive reference. Understanding the internals of SQL Server helps database developers and administrators to better create, access, and effectively process information from enterprise data. Written by experts on SQL Server, this volume from the Inside Microsoft SQL Server series of books focuses on query tuning and optimization. You'll take an in-depth look at the best ways to make queries more efficient and effective, while maximizing existing resources. Includes extensive code samples and table examples to help database developers and administrators understand the intricacies and help promote mastery of query tuning and optimization.

2009-09-24

Microsoft Press - Inside Microsoft SQL Server 2005 Query Tuning and Optimization (Sep 2007).chm

Dive deep into the internals of query tuning and optimization in SQL Server 2005 with this comprehensive reference. Understanding the internals of SQL Server helps database developers and administrators to better create, access, and effectively process information from enterprise data. Written by experts on SQL Server, this volume from the Inside Microsoft SQL Server series of books focuses on query tuning and optimization. You'll take an in-depth look at the best ways to make queries more efficient and effective, while maximizing existing resources. Includes extensive code samples and table examples to help database developers and administrators understand the intricacies and help promote mastery of query tuning and optimization.

2009-09-24

Inside Microsoft SQL Server 2005: T-SQL Programming

Written by a T-SQL guru, this thorough, hands-on reference for database developers and administrators focuses on language features and how they are interpreted and processed by the SQL Server execution engine.

2009-09-24

SQL.Server.2005.Administration

There you are, standing in front of the book rack at your favorite book store, leafing through these pages, wondering if this is the one you are looking for. Go ahead; look around to see if I’m watching you. I’ll wait.... OK, the coast is clear. So, did we write this book for you? Since you’re reading this, it’s very likely. Our primary audience is IT professionals (both developers and administrators) who have found themselves responsible for the management and maintenance of a SQL Server 2005 database. You may have been responsible for a SQL Server 2000 database and were just getting used to that when your company decided to move to SQL Server 2005. The new features and new tool set can be intimidating. We wrote this book for you. You may be thinking, “I’m a senior DBA and this book’s title is Beginning SQL Server 2005 Administration. I am not a beginner.” I understand. However, we also wrote this book for you. SQL Server 2005 is a dramatic departure from its predecessors and, even if you are an expert on SQL Server 2000 or SQL Server 7, you will find a great deal of very useful information in this book. Go ahead, flip through the pages, and check it out for yourself. I believe you will find what you’re looking for.

2009-05-25

TSQL Query Tuning

This article is the second in a series that describes a variety of performance tuning techniques that you can apply to your Microsoft SQL Server Transact-SQL programs. In many cases, you could use the graphic user interface provided in Microsoft SQL Enterprise Manager or Microsoft SQL Query Analyzer to achieve the same or similar results to those described here. However, this series focuses on using Transact-SQL as the basis for our solutions. All examples and syntax are verified for Microsoft SQL Server 2000.

2009-05-25

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除