Search code examples
sql-serverssmsresultset

How to keep results from previous queries viewable in SSMS


In RStudio, when I run queries in the top left Editor Pane, they appear in the bottom left Console Pane. New query results simply populate underneath the last one I ran. This makes it easy for me to go back and see results generated from prior queries which has been helpful when needing to compare results from other queries, and/or debug my code.

In SQL Server Management Studio (SSMS), every single time I run a query, it overwrites the results from the last one. I can't find the preferences setting in SQL Server to make it leave prior results in that pane, and just put the new results below the last. I've searched here and the internet but must be using wrong key words for the search.


Solution

  • SSMS doesn't have this feature. If you want to temporarily (or permanently) save the results of a query, open a new query (Ctrl + N) and run it in that separate window.