Clive Roberts

SQL DBA

Menu
  • Server Setup Scritps
  • mssql
  • Scripts
  • MS Notification Services

Month: April 2015

CODE: Tables without clustered indexes defined

April 15, 2015
| No Comments
| mssql

To analyze further, the following query can be used to find out which indexes don’t have clustered indexes defined: WITH CTE_1 AS ( SELECT db_name() as dbname, o.name as tablename, (SELECT SUM(p.rows) FROM sys.partitions p WHERE p.index_id = i.index_id AND i.object_id = p.object_id) as number_of_rows FROM sys.indexes i INNER JOIN sys.objects o ON i.object_id =…

Read More »

Posted in mssql

Blocking, Timeouts and Deadlocks

April 7, 2015
| No Comments
| mssql

These three issues are all related, yet very different. When we deal with reports of problems, it’s essential to clearly identify what is actually happening. Sometimes, we need clarification by asking about the symptoms, instead of accepting what the user says without delving any deeper. The root cause of a problem may not even be…

Read More »

Posted in mssql

Categories

Sidebar

  • November 2017 (1)
  • March 2017 (1)
  • October 2016 (13)
  • July 2016 (1)
  • May 2016 (1)
  • April 2016 (2)
  • March 2016 (1)
  • February 2016 (1)
  • November 2015 (2)
  • October 2015 (1)
  • September 2015 (1)
  • August 2015 (1)
  • July 2015 (7)
  • June 2015 (1)
  • May 2015 (6)
  • April 2015 (2)
  • March 2015 (2)
  • February 2015 (1)
  • January 2015 (1)
  • December 2014 (1)
  • November 2014 (1)
  • October 2014 (1)
  • September 2014 (1)
  • August 2014 (1)
  • July 2014 (1)
  • June 2014 (1)
  • May 2014 (1)
  • April 2014 (1)
  • March 2014 (1)
  • February 2014 (1)
  • January 2014 (1)
  • December 2013 (1)
  • November 2013 (1)
  • August 2013 (1)
  • July 2013 (1)
  • June 2013 (1)
  • April 2013 (1)
  • March 2013 (1)
  • February 2013 (1)
  • January 2013 (1)
  • December 2012 (1)
  • August 2012 (1)
  • June 2012 (1)
  • May 2012 (1)
  • April 2012 (1)
  • March 2012 (1)
  • February 2012 (1)
  • January 2012 (1)
  • October 2011 (1)
  • September 2011 (1)
  • August 2011 (1)
  • July 2011 (1)
  • June 2011 (1)
  • May 2011 (1)
  • April 2011 (1)
  • March 2011 (1)
  • January 2011 (1)
  • December 2010 (1)
  • September 2010 (1)
  • August 2010 (1)
  • July 2010 (1)
  • May 2010 (1)
  • March 2010 (1)
  • February 2010 (1)
  • January 2010 (1)
  • Server Setup Scritps
  • mssql
  • Scripts
  • MS Notification Services