restore tabs after reopening SQL Server Management Studio

18,749

Solution 1

There is a built-in way to do mostly this, but it is not going to open any random tabs that were there when you closed SSMS.

You can create a Solution in SSMS and save it with any set of SQL scripts. This works much like Visual Studio. You can even save connections (server + login info). The FILE menu has options to "Close Solution" as well as "Open Project/Solution" and "Recent Projects and Solutions".

So, if you create a Solution, add some Queries (i.e. .sql scripts), and then close the solution either via the FILE menu or just closing SSMS, when you open that Solution again it will restore the tabs that you had open at the time the Solution / SSMS was closed.

I just tested this in SSMS 2012, though it might have started as far back as SQL Server 2005. Even if not in 2005, this feature should definitely be in 2008 / 2008 R2.

Not exactly as open-ended as the FireFox / Chrome feature as it requires a defined Solution with defined .sql files, but definitely close.

Solution 2

Solution 3

How about running the Studio inside a VMWare and simply suspend the VMWare between sessions?

For my development purposes I use a VMWare that only runs an instance of SQL Server and the Mangement Studio. Maybe it's overkill for DB development but it helps in testing the integration of the database into a networked environment.

Share:
18,749
larryq
Author by

larryq

Updated on July 06, 2022

Comments

  • larryq
    larryq almost 2 years

    I don't suppose there's a way to emulate a FireFox-type of setup, whereby if I close SQL Server Management Studio (2008) my open tabs will be there again when I restart? I know I can save the individual windows into a .sql file but was wondering if there was a way for those tabs to reopen with the text in them on their own.

    Any third party tools that do something like this, perhaps? Thanks for the advice.

    -Larry