SQL Editions Testing
Remember to test your applications not only using SQL Server Developer Edition. Check how it is working under different editionsversions.
Today I was helping one team to speedup a mysterious long running report. Under local testing environment the report took about 90 seconds to complete. However at the client site, it was unable to complete (it was stopped after 30 minutes or so). It was the same database and better hardware. Report seemed very simple – several joins, several aggregates and one big non-correlated subquery (joins and except).
It turned out to be the suboptimal plan generated by standard edition. The query was split, subquery saved to a temp table and then used in the outer query. Running time: 30 seconds.