What factors should I be aware of that can cause excessive stored procedure recompilation?
Examples of the code that will cause a stored procedure to recompile would
Certain SET options can cause stored procedure recompilation or even multiple recompilations in one execution!
Some of these options may be not even inside the SP
--this will cause recompilation
SET concat_null_yields_null ON;
EXEC spMyProc;
Some of the options that cause recompilation when inside the SP:
ARITHABORT
ANSI_NULLS
QUOTED_IDENTIFIER
Luckily, this one doesn't cause the recompilation: SET NOCOUNT ON;