开发者

SQL Server stored procedure performance issues

开发者 https://www.devze.com 2023-03-05 15:56 出处:网络
We have function they call lot of stored procedures on our project. Sometimes somestored procedures work very slowly when we alter stored procedure, p开发者_运维问答roblems fixed but after 10 days pr

We have function they call lot of stored procedures on our project.

Sometimes some stored procedures work very slowly when we alter stored procedure, p开发者_运维问答roblems fixed but after 10 days problems occurs again. We use reindexing, optimizing query etc...

But we did not find any stable solution.

Does anyone have idea about this type of problem

thanks...


If the stored procedures randomly run slowly and running an alter on them sorts it out then this sounds like a parameter sniffing issue.

Running an ALTER will cause the cached plan to be dropped for that procedure and it will be recompiled on the next execution. A good article on the area is here


You may need to update your statistics.

EXEC sp_updatestats
0

精彩评论

暂无评论...
验证码 换一张
取 消