May 29, 2017 at 5:36 am
Hi Team,
How to get execution plan of a SQL which has executed two days back?
And how to compare two execution plans?
May 29, 2017 at 5:50 am
krishnabudampati - Monday, May 29, 2017 5:36 AMHi Team,How to get execution plan of a SQL which has executed two days back?
And how to compare two execution plans?
Grab this book SQL Server Execution Plans, 2nd Edition by Grant Fritchey
😎
May 29, 2017 at 7:53 am
krishnabudampati - Monday, May 29, 2017 5:36 AMHow to get execution plan of a SQL which has executed two days back?
Unless that plan is still in cache, you don't. SQL doesn't keep historical record of plans (well, not in 2014). You can try querying sys.dm_exec_cached_plans and sys.dm_exec_query_plan, however if the plan is not the one you're looking for, there will be no way to get it.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply