Here is an interesting question, I received the other day.
I have a very big graphical execution plan and I want to send it to my friend. My first thought was to send him query to execute on his own machine, but he does not have the same database which I am using. I also do not want to send my large database to him.
How can I save the execution plan to my computer and send it to him via email? Additionally, my email support only maximum of 20 MB, so please also guide me, what should I do if the size goes over 20 MB?
It is indeed a very interesting question. Here is the simplest way to do what the user is asking in the email.
Here is a quick tutorial.
Step 1: You can write any query and click on the icon on the top tool bar or type shortcut CTRL+M to enable actual management studio.
Step 2: Click on Execute Query
Step 3: It will execute the query and will bring up Execution Plan Tab. Click on the Execution Plan Tab.
Step 4: Upon clicking on Execution Plan it will bring up a query execution plan. Right Click over here and it will bring up a menu. In this menu click on the Save Execution Plan As…
Step 5: You can save your file with the extension.sqlplan.
That’s it! You are done. Now you can send the sqlplan via email to anyone. When someone opens the file, it will open in SQL Server Management Studio as displayed in the following image. The user has no need to have any database on their system. They can just see the data fine in the sqlplan.
You can open the sqlplan file in the notepad and you will see xml details for the plan.
Reference : Pinal Dave (https://blog.sqlauthority.com)