SQL SERVER – The NOLOCK Question – Notes from the Field #117

[Note from Pinal]: This is a 117th episode of Notes from the Field series. Everytime I go to do performance tuning consultancy, one thing annoys me and makes me angry. The usage of NOLOCK hint. I think without any argument, this is one of the most abused query hint in the SQL Server universe. Lots of people treat NOLOCK as a silver bullet of performance tuning and that is unfortunate. There is a special purpose of how NOLOCK should be used and what is the end goal of it.

In this episode of the Notes from the Field series database expert Stuart Ainsworth explains about NOLOCK and its best practices. Trust me, you do not want to overuse NOLOCK hint as it can just impact your database integrity negatively.

Read More

SQL SERVER – Three Simple Guidelines for System Maintenance – Notes from the Field #098

[Note from Pinal]: This is a 98th episode of Notes from the Field series. Maintenance of the database is a very critical activity and I have always seen DBA taking it very seriously. There is a only one problem – there is no single solution or guidance for how to maintain the database. Everybody has their own opinion and way to do different tasks. System maintenance is very straight forward task but I have seen quite often experts even getting confused with the same. Many only focus on index maintenance, statistics maintenance and a few other tasks are common, but understanding the real philosophy of this task is something beyond indexes. When I asked my good friend Stuart about system maintenance, he came up with very interesting guidelines for system maintenance.

Read More

SQL SERVER – DMV to Identify Incremental Statistics – Performance improvements in SQL Server 2014 – Part 3

This is the third part of the series Incremental Statistics. Here is the index of the complete series.
What are Incremental Statistics? – Performance improvements in SQL Server 2014 – Part 1
Simple Example of Incremental Statistics – Performance improvements in SQL Server 2014 – Part 2
DMV to Identify Incremental Statistics – Performance improvements in SQL Server 2014 – Part 3

Read More