When you build a monitoring tool that sends advice via email, you discover two things:
Some people have really, really big execution plans Email servers have reasonable limits on file attachment sizes
Add those two things together, and Richie found himself working on a new feature for SQL ConstantCare® that would automatically break up advice into multiple emails if we needed to attach several big query plans. He needed to test it, so I whipped up some T-SQL that would quickly build a large query plans.
You can copy/paste this directly into SSMS, no prep required, and get the estimated