Recently I have received a very interesting question in an email. The user wanted to know how will trigger behave when there are nested triggers. In an email, he described a scenario where trigger called another trigger. I really liked the question and immediately answered in the email as well. However, I believe many others may have the same question, so decided to write this blog post with an example.
How to Drop All the User Created Statistics by SQL Server? – Interview Question of the Week #158
Question:Â How to Drop All the User Created Statistics by SQL Server?
SQL SERVER – 2017 – Script to Clear Procedure Cache at Database Level
When my customer ask they want to clear the cache of the database, I always so NO. It is not necessary. However, I have come to the realization that customers are always right and sometimes even though I say no, they still want to do it. One way or another way, they will eventually do what they want. Let us learn about Script to Clear Procedure Cache at Database Level.
SQL SERVER – Simple Script to Match Session ID to OS Thread ID
I often get asked a question about how actually Session ID of SQL Server is mapped to Operating System’s’ Thread ID. Well, the answer is very simple, here is the script which provides us three important details – SQL Session ID, OS Thread ID and OS Scheduler ID along with the state of the task.Â
SQL SERVER – Authentication in SQL Server (Windows and Mixed Mode) – GDPR Series
On May 25, 2018, European privacy law is going to enforce new global standards for privacy rights, security, and compliance. This new regulation is known as GDPR – General Data Protection Regulations. Lots of users who are using SQL Server often wonder How to make SQL Server GDPR compliance? Before you read this blog post, I suggest you read my earlier blog post about here which explains everything about GDPR. This blog post we will take about Authentication in SQL Server (Windows and Mixed Mode) which is for GDPR Article 25.
SQL SERVER – Identity Jumping 1000 – IDENTITY_CACHE
SQL Server 2017 has a wonderful feature which fixes a very old issue which DBA and developers have been struggling for a while. It would be impossible to find DBA or Developer who has not faced an issue when their identity column value has jumped or incremented by 1000. It is a very common issue and today we will see the solution of this issue with the help of IDENTITY_CACHE introduced in the latest version of SQL Server.Â
SQL SERVER – How to Kill All the Processes for Any Database?
Recently during Comprehensive Database Performance Health Check, to test our unique fix, we had to run a stress test on my customer’s development environment. Once we were done testing our script, we did not need our stress test queries to run on our server. Even though we stopped to run the batch file with stress test queries, there were few long-running queries kept on running on the server. This brought us to a very interesting point where we had to kill all the processes for one particular database.





