▲ 11 r/DBA
query was fine for a year then suddenly slow, turned out the plan changed
We had a query that ran fine for about a year. No code change, no new data, nothing deployed. One morning it was slow and the app team was on us.
The execution plan had changed. It picked a different join and fell over. Once I saw that, I pinned the plan and it was fine.
Working out that the plan had changed at all took most of the morning. Nothing flags it on its own, so I was comparing it by hand to an older plan.
how do you catch a plan change like this before users start complaining?
u/VarunDba — 14 days ago