September 22, 2017 at 9:19 am
Hello Everyone,
I just recently updated my SSMS to 17.2 and now I am noticing that when I open a stored procedure, the following code is placed at the top:
/* ==Scripting Parameters==
Source Server Version : SQL Server 2016 (13.0.4001)
Source Database Engine Edition : Microsoft SQL Server Standard Edition
Source Database Engine Type : Standalone SQL Server
Target Server Version : SQL Server 2017
Target Database Engine Edition : Microsoft SQL Server Standard Edition
Target Database Engine Type : Standalone SQL Server
*/
Is there any way to turn this feature off? I know it's only comments but I don't want anything automatically added to the scripts.
Thanks!
September 22, 2017 at 9:24 am
meichmann - Friday, September 22, 2017 9:19 AMHello Everyone,
I just recently updated my SSMS to 17.2 and now I am noticing that when I open a stored procedure, the following code is placed at the top:/* ==Scripting Parameters==
Source Server Version : SQL Server 2016 (13.0.4001)
Source Database Engine Edition : Microsoft SQL Server Standard Edition
Source Database Engine Type : Standalone SQL Server
Target Server Version : SQL Server 2017
Target Database Engine Edition : Microsoft SQL Server Standard Edition
Target Database Engine Type : Standalone SQL Server
*/
Is there any way to turn this feature off? I know it's only comments but I don't want anything automatically added to the scripts.
Thanks!
The comments aren't added to the SP on the server, they're simply there so that you're aware of the format that SSMS has created the script in. As there are several versions of SQL Server current supported (2008, 2008R2, 2012, 2014, 2016, and soon 2017, along with those having different licences such as Express, Standard, Enterprise, and you also have Azure to add to that mix), it could be quite important to know that the script generated by SSMS is designed for a particular edition.
For example, the comments in your script show that you're using SQL Server 2016, but the scripts generated are designed with SQL Server 2017 in mind. (I have no idea if they actually really differ to a 2016 design though).
Thom~
Excuse my typos and sometimes awful grammar. My fingers work faster than my brain does.
Larnu.uk
September 22, 2017 at 9:37 am
Go to Menu->Tools->Options...
Choose the tab SQL Server Object Explorer -> Scripting
I'm not sure if it can be removed, but you can search through the available options. I don't have SSMS 17.2 to be sure.
September 22, 2017 at 9:43 am
Luis Cazares - Friday, September 22, 2017 9:37 AMGo to Menu->Tools->Options...
Choose the tab SQL Server Object Explorer -> Scripting
I'm not sure if it can be removed, but you can search through the available options. I don't have SSMS 17.2 to be sure.
I had a look before replying, however, I couldn't see an option to disable. Only to enforce to target version.
Thom~
Excuse my typos and sometimes awful grammar. My fingers work faster than my brain does.
Larnu.uk
September 22, 2017 at 9:50 am
It adds the comments. if you export the query to a text file, the comments show up there as well.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply