How to Find Recent Executed Queries in SQL Server? – Interview Question of the Week #087

Interviews are fun. Most of the time the interviewer has all the interesting questions, but I often come across a few individuals who stomps the interviewer. I was recently called by one of the organizations where I regularly help with their hiring process. They were stumped by interviewing candidates with one of the questions related to recent executed queries. Let us see the question and its answer.

Read More

SQL SERVER – Stored Procedure are Compiled on First Run – SP taking Longer to Run First Time

During the PASS summit, one of the attendees asked me the following question. Why the Stored Procedure takes long time to run for first time? The reason for the same is because Stored Procedures are compiled when it runs first time. When I answered the same, he replied that Stored…
Read More

SQL SERVER – Plan Caching and Schema Change – An Interesting Observation

Last week, I had published details regarding SQL SERVER – Plan Caching in SQL Server 2008 by Greg Low on this blog. Similar to any other white paper, I have read this paper very carefully and enjoyed reading it. One particular topic in the white paper that caught my attention…
Read More

SQL SERVER – 2005 – Different Types of Cache Objects

About two months ago I reviewed book SQL Server 2005 Practical Troubleshooting: The Database Engine. Yesterday I received a request from reader, if I can write something from this book, which is not common knowledge in DBA community. I really like the idea, however I must respect the Authors copyright about this book. This book is unorthodox SQL book, it talks about things which can get you to fix your problem faster, if problem is discussed in book. There are few places it teaches behind the scene SQL stories.

Read More