How to check blocking queries in SQL Server
12:12 10 Dec 2016

I have one warehouse server which got data/sync from legacy system 24/7, I noticed some of my reports/sql jobs performance is uncertain and most of the time I heard from DBA team that my query is blocking to other sync process.

From DBA team I came to know command i.e. EXEC SP_WHO2 by which I can identify spid of query which cause blocking by looking into column BlkBy.

Please suggest me how I can avoid blocking and other ways to check blocking in SQL Server

sql-server sql-server-2008 sql-server-2005 sql-server-2012 sql-server-2008-r2