Enabling Growth Through Performance
Enabling Growth Through Performance

Posts Tagged ‘SQL Server’

SQL Script Generation

SQL Script Generator

How many times have you needed to script out a table from a SQL Server database? What about all of the indexes? Or maybe it was just the procedures in a particular schema? Or export all of your data as insert/update statements? Boy have we got the tool for you! Be sure to stick it…

Read More

Mapping a Drive with XP_CMDSHELL

Today I want to talk about one of my favorite tricks that’s not talked about much: mapping a network drive under the SQL Server account. You see, mapped drives are “per user” – so if you map one on the SQL server, then SQL server can’t see it. Likewise, if you map one for SQL…

Read More

Enable and Disable xp_cmdshell

xp_cmdshell is one of those somewhat hidden gems/power-tools in SQL Server that can both make life easy and very insecure all at the same time. You see, this function allows any SQL Server administrator to run any command/program/shell-script/batch-file that the SQL Server account has access to. It seems counter-intuitive at first but I’ve seen this…

Read More

Cost Threshold for Parallelism and MAXDOP

There are a lot of “most overlooked” configuration settings in SQL Server, but I’m going to cover these two alone since they are quite closely related: Cost Threshold for Parallelism and Max Degree of Parallelism. What’s all this about? First let’s discuss Degree of Parallelism in its most simple form. When given a task to…

Read More

How can I use ephemeral drives with SQL Server tempdb?

First of all, if you are not familiar with ephemeral storage, then check out our previous post on the topic. SQL Server loves to use tempdb and believe it or not it’s not relegated solely to the types of queries you might think, such as ordering and grouping. It’s used by a whole world of…

Read More

Creating an Extended Events Session

Creating an extended events session is pretty straight forward with SQL Server 2012 as Microsoft has finally introduced a graphical user interface. During my time as a DBA, I often needed to create a quick trace to capture query activity for a particular table. So, let’s run through how we might do this with extended…

Read More

Tracing Events in SQL Server

When you want to trace or instrument SQL Server activity, whether it be for performance purposes, security, auditing, etc. – you really have two baked in methods. Well, there are a few others – but they are not all that robust. Tracing with SQL Profiler Tracing with SQL Server profile is the good ol’ way…

Read More

SQL Server Data Compression

When people talk about data compression they are typically discussing archival – but Microsoft has used this very popular technology in a way that has managed to fall into the category of performance improvement. Here I am going to give you an example of how we can use compression to decrease disk latency, maximize memory…

Read More