Problem

Sometime we may write a SQL script to verify the data or monitor any activities or adhoc tasks in database. In that case, We opens “N” number of Query windows and continue our activities in SSMS. We may not required to keep/save the scripts, but when we  close the windows we will get as many number of prompts for save/cancel the changes. also you will be forced to click each and every annoying save prompts.

Solution:

This Problem is resolved in SSMS 2016 release.

Microsoft has provided a new option to avoid prompting for saving unsaved files.
To use this feature, Go to “Tools” Menu > Options > Query Execution > SQL Server > General > Un-check “Prompt to save unsaved T-SQL query windows on close”
 
Note:
You have to disable this option before open any query window, otherwise SSMS will prompt the save changes window at the time of closing

Warning:

 

Do not disable this option, if you do, you may lose valid scripts one day if you forget to save the changes when you close any script accidentally. so don’t forget to enable this option after use.
Requested By:
A connect item was raised to add this feature by Erland Sommarskog, Refer
Connect #308372, which replaced Connect #124686. It was denied by Microsoft earlier and closed the ticket stating as “Won’t Fix”, But due to Many People requests, Now Microsoft has introduced this feature in SQL 2016

 

Categories: SQL 2016

Related Posts

JSON

Introducing JSON for SQL Server 2016

Problem On my current project, there is a requirement to extract data, which is stored in one database (D1) and load it into another database (D2). That should be simple, right? But, the client is Read more…

SQL 2016

SQL 2016 – Automatic Check for Updates

SQL SERVER 2016 – Automatic Check for Updates (New Features in SSMS)   Now you can upgrade your SQL server with latest updates via SSMS 2016 as well, This feature is introduced in SQL 2016 CTP Read more…

SQL 2016

SQL 2016 – Rule "Oracle JRE 7 Update 51 (64-bit) or higher is required

Problem Today trying to install SQL 2016 CTP2.2 in my system.