Monday, July 18, 2011

Recompiling Stored Procedures

If we edit a stored procedure, it is recompiled the very first time it is executed. So the program using this Stored Procedure may see delay during this period (as it is being recompiled).

But we can force SQL Server to recompile Stored Procedure by using WITH RECOMPILE option

Example:exec usp_TestProcedure WITH RECOMPILE

No comments:

Post a Comment

How to upload app to macOS

1. Open Terminal Press Cmd (⌘) + Space , type Terminal , and hit Enter . 2. Navigate to Your Build Output Directory Your .app file is likel...