TSQL – Get All Queries Currently Running

August 4, 2016 | 0 Comments

This is perhaps my most commonly used query when troubleshooting. From SQL Server DMV’s in action ebook. The output shows the spid (process identifier), the ecid (this [...]

Generate Red Gate MultiScript .dat File

July 14, 2016 | 0 Comments

This is a PowerShell script that puts out the XML required to update your Red Gate MultiScript servers.  Manually entering the SQL instances from within the application [...]

T-SQL – Get Listener Name on AlwaysOn Cluster

May 25, 2016 | 0 Comments

When using AlwaysOn, you must connect using your listener name, not your node name.  If you connect with the node name, it will only work until there is a failover, which would defeat the purpose of your High Availability setup, right?


PowerShell – Check If Module Is Loaded

May 18, 2016 | 0 Comments

This is how to check if a particular module is loaded, and if it’s not then load it. SQLPS is the module used in the example, but you can replace that with any module [...]

SQL Server – Timestamp Column

May 2, 2016 | 0 Comments

While this seems like a simple thing to do, I recently discovered so many ways not to do it (also known as failing) that I just had to document this one.

1 2 3 4 5 11