SQLAuthority News – MUGH – Microsoft User Group Hyderabad – Feb 2, 2010 Session Review

Earlier this month, I was very fortunate to visit Microsoft User Group Hyderabad lead by Hima Vindu Vejella. Hima is a very enthusiastic leader and kind person. I had a wonderful time meeting her as well her husband during my visit to Hyderabad. I had presented session on Index, which…
Read More

SQL SERVER- IF EXISTS(Select null from table) vs IF EXISTS(Select 1 from table)

Few days ago I wrote article about SQL SERVER – Stored Procedure Optimization Tips – Best Practices. I received lots of comments on particular blog article. In fact, almost all the comments are very interesting. If you have not read all the comments, I strongly suggest to read them. Click…
Read More

SQL SERVER – Recompile Stored Procedure at Run Time

I recently received an email from reader after reading my previous article on SQL SERVER – Plan Recompilation and Reduce Recompilation – Performance Tuning regarding how to recompile any stored procedure at run time. There are multiple ways to do this. If you want your stored procedure to always recompile at run time, you can add the keyword RECOMPILE when you create the stored procedure. Additionally, if the stored procedure has to be recompiled at only one time, in that case, you can add RECOMPILE word one time only and run the SP as well. Let us go over these two options.

Read More