Azure SQL Database View Running Transactions / Blocking

With the Azure SQL Database, sometimes you want to view the current running transactions. Unfortunately there is no GUI as such like there is with normal SQL Server (right click, “Activity Monitor”), however it can be grabbed by executing sys.dm_exec_requests. The following SQL is very useful as it shows details…

Azure SQL Database Index Size

Recently I’ve been doing some work on optimising indexes within Azure SQL Database. The following SQL from Daniel is very useful in showing the status of all the current indexes within a SQL Database. The SQL works for both SQL Server 2014 onwards, plus Azure SQL Database. I have not…

Azure AD Connect – Force Sync Via Command Line

Azure AD connect is a new tool which replaces DirSync for syncing Active Directory information to Azure from the local active directory. Synchronisation automatically works in the background, but sometimes you want to push through a synchronisation for some reason or another (rather than waiting for the next time it…

Microsoft Azure – Redis

Microsoft have implemented the open-sourced Redis key-cache and store in Azure. Similar to have there are “Basic” and “Standard” levels of Virtual Machines, with associated redundancy, with Redis there are the same options available: Basic – Single node Standard – 2 node (in a primary/secondary setup), with built in replication…

Monitoring Azure SQL Database CPU Usage

Sometimes there is a need to monitor Microsoft’s Azure SQL database usage, but your after the raw figures rather than an impressive looking graph. Running the following SQL against the master database will give you the recent information: DECLARE @DatabaseName nvarchar(50); SET @DatabaseName = '*databasename*'; SELECT getdate() AS [Current Server…