Tags » T-SQL

Using Not Exists to get Noncompliant Servers

Sometimes you need to perform a check against all servers to verify settings are correct. There are many ways to do this, but in some cases, you just need an idea of how many servers have “fallen through the cracks”.   407 more words

SQL Server

Hey DBA - Protecting a Proactive Attitude - Notes from the Field #069

: This is a 69th episode of Notes from the Field series. Mike Walsh is an amazing person to meet and know. I am fortunate to be his friend. 931 more words

SQL Authority

A Well needed Foreign key query for T-SQL

What is one of the biggest pains of troubleshooting data manipulation in a database? Foreign key constraints. So one guys posted in Stack Overflow a query that mines every foreign key constraint out of your database for you. 158 more words

Brian's Code Extreme

COUNT function and NULL values in T-SQL

Simple and basic rule: Except for COUNT, aggregate functions ignore null values (Source: https://msdn.microsoft.com/en-us/library/ms173454.aspx). Just remember this rule! But there is a catch to this simple rule. 230 more words

Using sp_DBPermissions and sp_SrvPermissions v6.0

It’s been a while since I posted an updated to usp_DBPermissions and usp_SrvPermissions. Sorry. I got lazy with my posting.


— V5.5
— 7/22/2014 – Changed strings to unicode… 646 more words

Microsoft SQL Server

Mirroring with TDE

Recently I’ve had to set up a lot of database mirroring, and about half of those databases were encrypted. Setting up mirroring on unencrypted databases is normally a quick process, but encrypted mirroring requires a bit more work.  1,067 more words