SQL server stored proc caching
"Stored procedures are just SQL code that is pre-compiled, meaning that execution plans, etc. are often created in advance."
Actually, that's false for a lot of big and small databases including MS SQL Server. It doesn't treat stored procedures any differently than regular queries in caching of execution plans, etc
I think the are cached
July 29th, 2007 5:21pm
This may be version dependent, but I think on the whole, you are right -- when SQL Server 200x starts up, the procedure cache is empty. Only when the sproc gets executed for the first time does it end up in the cache (after having been compiled, verified, etc. etc.), just like any other query.
xampl
July 29th, 2007 6:34pm